mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-05 11:19:23 +01:00
DBG: Enable/Disable breakpoint groups
git-svn-id: trunk@32788 -
This commit is contained in:
parent
5b3c4cf5f1
commit
064e148c79
@ -93,41 +93,11 @@ end;
|
|||||||
|
|
||||||
procedure TBreakPropertyDlg.chkDisableGroupsChange(Sender: TObject);
|
procedure TBreakPropertyDlg.chkDisableGroupsChange(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
{$IFdef MSWindows}
|
|
||||||
if (not FUpdatingInfo) and (not EnvironmentOptions.DebuggerConfig.WarnedAboutBreakGroup)
|
|
||||||
then begin
|
|
||||||
if MessageDlg('Beta Feature', 'This feature requires special setup, See DEBUG-README.TXT. Continue?',
|
|
||||||
mtConfirmation, mbYesNo, 0)
|
|
||||||
<> mrYes
|
|
||||||
then begin
|
|
||||||
FUpdatingInfo := True;
|
|
||||||
chkDisableGroups.Checked := False;
|
|
||||||
FUpdatingInfo := False;
|
|
||||||
exit;
|
|
||||||
end;
|
|
||||||
EnvironmentOptions.DebuggerConfig.WarnedAboutBreakGroup := True;
|
|
||||||
end;
|
|
||||||
{$ENDIF}
|
|
||||||
edtDisableGroups.Enabled := chkDisableGroups.Checked;
|
edtDisableGroups.Enabled := chkDisableGroups.Checked;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TBreakPropertyDlg.chkEnableGroupsChange(Sender: TObject);
|
procedure TBreakPropertyDlg.chkEnableGroupsChange(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
{$IFdef MSWindows}
|
|
||||||
if (not FUpdatingInfo) and (not EnvironmentOptions.DebuggerConfig.WarnedAboutBreakGroup)
|
|
||||||
then begin
|
|
||||||
if MessageDlg('Beta Feature', 'This feature requires special setup, See DEBUG-README.TXT. Continue?',
|
|
||||||
mtConfirmation, mbYesNo, 0)
|
|
||||||
<> mrYes
|
|
||||||
then begin
|
|
||||||
FUpdatingInfo := True;
|
|
||||||
chkEnableGroups.Checked := False;
|
|
||||||
FUpdatingInfo := False;
|
|
||||||
exit;
|
|
||||||
end;
|
|
||||||
EnvironmentOptions.DebuggerConfig.WarnedAboutBreakGroup := True;
|
|
||||||
end;
|
|
||||||
{$ENDIF}
|
|
||||||
edtEnableGroups.Enabled := chkEnableGroups.Checked;
|
edtEnableGroups.Enabled := chkEnableGroups.Checked;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|||||||
@ -197,9 +197,7 @@ type
|
|||||||
private
|
private
|
||||||
FDebuggerClass: String;
|
FDebuggerClass: String;
|
||||||
FTDebuggerWatchesDlgConfig: TDebuggerWatchesDlgConfig;
|
FTDebuggerWatchesDlgConfig: TDebuggerWatchesDlgConfig;
|
||||||
FWarnedAboutBreakGroup: Boolean;
|
|
||||||
public
|
public
|
||||||
procedure Init; override;
|
|
||||||
procedure Load; override;
|
procedure Load; override;
|
||||||
procedure Save; override;
|
procedure Save; override;
|
||||||
public
|
public
|
||||||
@ -208,9 +206,6 @@ type
|
|||||||
property DebuggerClass: String read FDebuggerClass write FDebuggerClass;
|
property DebuggerClass: String read FDebuggerClass write FDebuggerClass;
|
||||||
property DlgWatchesConfig: TDebuggerWatchesDlgConfig read FTDebuggerWatchesDlgConfig;
|
property DlgWatchesConfig: TDebuggerWatchesDlgConfig read FTDebuggerWatchesDlgConfig;
|
||||||
published
|
published
|
||||||
{$IFdef MSWindows}
|
|
||||||
property WarnedAboutBreakGroup: Boolean read FWarnedAboutBreakGroup write FWarnedAboutBreakGroup;
|
|
||||||
{$ENDIF}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TFreeNotifyingObject }
|
{ TFreeNotifyingObject }
|
||||||
@ -3103,14 +3098,6 @@ end;
|
|||||||
|
|
||||||
{ TDebuggerConfigStore }
|
{ TDebuggerConfigStore }
|
||||||
|
|
||||||
procedure TDebuggerConfigStore.Init;
|
|
||||||
begin
|
|
||||||
inherited Init;
|
|
||||||
{$IFdef MSWindows}
|
|
||||||
WarnedAboutBreakGroup := False;
|
|
||||||
{$ENDIF}
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure TDebuggerConfigStore.Load;
|
procedure TDebuggerConfigStore.Load;
|
||||||
const
|
const
|
||||||
OLD_GDB_DBG_NAME = 'GNU debugger (gdb)';
|
OLD_GDB_DBG_NAME = 'GNU debugger (gdb)';
|
||||||
@ -6699,8 +6686,6 @@ begin
|
|||||||
if bpaLogCallStack in Actions
|
if bpaLogCallStack in Actions
|
||||||
then FMaster.DoLogCallStack(FLogCallStackLimit);
|
then FMaster.DoLogCallStack(FLogCallStackLimit);
|
||||||
// SnapShot is taken in TDebugManager.DebuggerChangeState
|
// SnapShot is taken in TDebugManager.DebuggerChangeState
|
||||||
if Actions * [bpaDisableGroup, bpaEnableGroup] <> []
|
|
||||||
then sleep(2500);
|
|
||||||
if bpaEnableGroup in Actions
|
if bpaEnableGroup in Actions
|
||||||
then EnableGroups;
|
then EnableGroups;
|
||||||
if bpaDisableGroup in Actions
|
if bpaDisableGroup in Actions
|
||||||
|
|||||||
@ -319,6 +319,7 @@ type
|
|||||||
FDebuggerFlags: TGDBMIDebuggerFlags;
|
FDebuggerFlags: TGDBMIDebuggerFlags;
|
||||||
FSourceNames: TStringList; // Objects[] -> TMap[Integer|Integer] -> TDbgPtr
|
FSourceNames: TStringList; // Objects[] -> TMap[Integer|Integer] -> TDbgPtr
|
||||||
FReleaseLock: Integer;
|
FReleaseLock: Integer;
|
||||||
|
FInProcessStopped: Boolean; // paused, but maybe state run
|
||||||
|
|
||||||
// Internal Current values
|
// Internal Current values
|
||||||
FCurrentStackFrame, FCurrentThreadId: Integer; // User set values
|
FCurrentStackFrame, FCurrentThreadId: Integer; // User set values
|
||||||
@ -4607,6 +4608,8 @@ begin
|
|||||||
Therefore all calls to ExecuteCommand (gdb cmd) must be wrapped in QueueExecuteLock
|
Therefore all calls to ExecuteCommand (gdb cmd) must be wrapped in QueueExecuteLock
|
||||||
*)
|
*)
|
||||||
Result := False;
|
Result := False;
|
||||||
|
FTheDebugger.FInProcessStopped := True; // paused, but maybe state run
|
||||||
|
|
||||||
List := TGDBMINameValueList.Create(AParams);
|
List := TGDBMINameValueList.Create(AParams);
|
||||||
List2 := nil;
|
List2 := nil;
|
||||||
|
|
||||||
@ -4733,6 +4736,7 @@ begin
|
|||||||
ProcessFrame(List.Values['frame']);
|
ProcessFrame(List.Values['frame']);
|
||||||
end;
|
end;
|
||||||
finally
|
finally
|
||||||
|
FTheDebugger.FInProcessStopped := False;
|
||||||
List.Free;
|
List.Free;
|
||||||
list2.Free;
|
list2.Free;
|
||||||
end;
|
end;
|
||||||
@ -5834,6 +5838,7 @@ begin
|
|||||||
FThreadGroups := TStringList.Create;
|
FThreadGroups := TStringList.Create;
|
||||||
FTypeRequestCache := TGDBPTypeRequestCache.Create;
|
FTypeRequestCache := TGDBPTypeRequestCache.Create;
|
||||||
FMaxLineForUnitCache := TStringList.Create;
|
FMaxLineForUnitCache := TStringList.Create;
|
||||||
|
FInProcessStopped := False;
|
||||||
|
|
||||||
|
|
||||||
{$IFdef MSWindows}
|
{$IFdef MSWindows}
|
||||||
@ -6585,6 +6590,8 @@ end;
|
|||||||
|
|
||||||
function TGDBMIDebugger.GDBPause(const AInternal: Boolean): Boolean;
|
function TGDBMIDebugger.GDBPause(const AInternal: Boolean): Boolean;
|
||||||
begin
|
begin
|
||||||
|
if FInProcessStopped then exit;
|
||||||
|
|
||||||
// Check if we already issued a break
|
// Check if we already issued a break
|
||||||
if FPauseWaitState = pwsNone
|
if FPauseWaitState = pwsNone
|
||||||
then InterruptTarget;
|
then InterruptTarget;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user