mirror of https://gitlab.com/basile.b/dexed.git
fix #440 - CPU subwindow of the debugger should be removable
This commit is contained in:
parent
75bced5d65
commit
148463c25d
|
@ -308,6 +308,7 @@ type
|
||||||
fAsmSyntax: TAsmSyntax;
|
fAsmSyntax: TAsmSyntax;
|
||||||
fKeepRedirectedStreams: boolean;
|
fKeepRedirectedStreams: boolean;
|
||||||
fStopAllThreadsOnBreak: boolean;
|
fStopAllThreadsOnBreak: boolean;
|
||||||
|
fHideCpuView: boolean;
|
||||||
fDlangBreakpoints: TDlangBreakpoints;
|
fDlangBreakpoints: TDlangBreakpoints;
|
||||||
procedure setIgnoredSignals(value: TStringList);
|
procedure setIgnoredSignals(value: TStringList);
|
||||||
procedure setCommandsHistory(value: TStringList);
|
procedure setCommandsHistory(value: TStringList);
|
||||||
|
@ -325,6 +326,7 @@ type
|
||||||
property commandsHistory: TStringList read fCommandsHistory write setCommandsHistory;
|
property commandsHistory: TStringList read fCommandsHistory write setCommandsHistory;
|
||||||
property coreBreakingSymbols: TDlangBreakpoints read fDlangBreakpoints write fDlangBreakpoints;
|
property coreBreakingSymbols: TDlangBreakpoints read fDlangBreakpoints write fDlangBreakpoints;
|
||||||
property customEvalHistory: TStringList read fCustomEvalHistory write setCustomEvalHistory;
|
property customEvalHistory: TStringList read fCustomEvalHistory write setCustomEvalHistory;
|
||||||
|
property hideCpuView: boolean read fHideCpuView write fHideCpuView default false;
|
||||||
property ignoredSignals: TStringList read fIgnoredSignals write setIgnoredSignals;
|
property ignoredSignals: TStringList read fIgnoredSignals write setIgnoredSignals;
|
||||||
property keepRedirectedStreams: boolean read fKeepRedirectedStreams write fKeepRedirectedStreams default false;
|
property keepRedirectedStreams: boolean read fKeepRedirectedStreams write fKeepRedirectedStreams default false;
|
||||||
property shortcuts: TDebugShortcuts read fShortcuts write setShortcuts;
|
property shortcuts: TDebugShortcuts read fShortcuts write setShortcuts;
|
||||||
|
@ -519,6 +521,7 @@ type
|
||||||
fLastEvalStuff: string;
|
fLastEvalStuff: string;
|
||||||
fCommandProcessed: boolean;
|
fCommandProcessed: boolean;
|
||||||
fDebugeeOptions: TDebugeeOptions;
|
fDebugeeOptions: TDebugeeOptions;
|
||||||
|
procedure updateCpuViewVisibility;
|
||||||
procedure continueDebugging;
|
procedure continueDebugging;
|
||||||
procedure waitCommandProcessed;
|
procedure waitCommandProcessed;
|
||||||
procedure clearDisplays;
|
procedure clearDisplays;
|
||||||
|
@ -1260,6 +1263,7 @@ begin
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
updateCpuViewVisibility;
|
||||||
updateMenu;
|
updateMenu;
|
||||||
updateButtonsState;
|
updateButtonsState;
|
||||||
end;
|
end;
|
||||||
|
@ -1288,6 +1292,14 @@ begin
|
||||||
varListFlt.flat := value;
|
varListFlt.flat := value;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TGdbWidget.updateCpuViewVisibility;
|
||||||
|
begin
|
||||||
|
if not GroupBox3.Visible then
|
||||||
|
PageControl2.Align:= alClient
|
||||||
|
else
|
||||||
|
PageControl2.Align:= alTop;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TGdbWidget.updateMenu;
|
procedure TGdbWidget.updateMenu;
|
||||||
var
|
var
|
||||||
mnu: IMainMenu;
|
mnu: IMainMenu;
|
||||||
|
@ -1428,6 +1440,8 @@ end;
|
||||||
procedure TGdbWidget.optionsChangesApplied(sender: TObject);
|
procedure TGdbWidget.optionsChangesApplied(sender: TObject);
|
||||||
begin
|
begin
|
||||||
updateMenu;
|
updateMenu;
|
||||||
|
GroupBox3.Visible := not fOptions.hideCpuView;
|
||||||
|
updateCpuViewVisibility;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TGdbWidget.executeFromShortcut(sender: TObject);
|
procedure TGdbWidget.executeFromShortcut(sender: TObject);
|
||||||
|
@ -2171,7 +2185,7 @@ procedure TGdbWidget.interpretJson;
|
||||||
begin
|
begin
|
||||||
if fOptions.autoGetCallStack then
|
if fOptions.autoGetCallStack then
|
||||||
infoStack;
|
infoStack;
|
||||||
if fOptions.autoGetRegisters then
|
if fOptions.autoGetRegisters and not fOptions.hideCpuView then
|
||||||
infoRegs;
|
infoRegs;
|
||||||
if fOptions.autoGetVariables then
|
if fOptions.autoGetVariables then
|
||||||
infoVariables;
|
infoVariables;
|
||||||
|
@ -2341,7 +2355,7 @@ begin
|
||||||
if fJson.findAny('msg', val) then
|
if fJson.findAny('msg', val) then
|
||||||
fMsg.message(val.AsString, nil, amcMisc, amkAuto);
|
fMsg.message(val.AsString, nil, amcMisc, amkAuto);
|
||||||
|
|
||||||
if fJson.findArray('register-values', arr) then
|
if not fOptions.hideCpuView and fJson.findArray('register-values', arr) then
|
||||||
begin
|
begin
|
||||||
for i := 0 to arr.Count-1 do
|
for i := 0 to arr.Count-1 do
|
||||||
begin
|
begin
|
||||||
|
@ -2605,6 +2619,8 @@ end;
|
||||||
|
|
||||||
procedure TGdbWidget.infoRegs;
|
procedure TGdbWidget.infoRegs;
|
||||||
begin
|
begin
|
||||||
|
if fOptions.hideCpuView then
|
||||||
|
exit;
|
||||||
disableEditor;
|
disableEditor;
|
||||||
gdbCommand('-data-list-register-values r', @gdboutJsonize);
|
gdbCommand('-data-list-register-values r', @gdboutJsonize);
|
||||||
end;
|
end;
|
||||||
|
|
Loading…
Reference in New Issue