mirror of
https://github.com/libretro/Mesen.git
synced 2025-03-03 13:58:20 +00:00
Debugger: Save debugger window size & bottom panel height
This commit is contained in:
parent
ba94e785dc
commit
8c209367a7
@ -88,6 +88,10 @@ namespace Mesen.GUI.Config
|
||||
public int RamColumnCount = 2;
|
||||
public float RamFontSize = 13;
|
||||
|
||||
public int WindowWidth = -1;
|
||||
public int WindowHeight = -1;
|
||||
public int BottomPanelHeight = -1;
|
||||
|
||||
public DebugInfo()
|
||||
{
|
||||
LeftView = new DebugViewInfo();
|
||||
|
@ -46,6 +46,12 @@ namespace Mesen.GUI.Debugger
|
||||
this.mnuShowOnlyDisassembledCode.Checked = ConfigManager.Config.DebugInfo.ShowOnlyDisassembledCode;
|
||||
this.mnuShowFunctionLabelLists.Checked = ConfigManager.Config.DebugInfo.ShowFunctionLabelLists;
|
||||
|
||||
this.Width = ConfigManager.Config.DebugInfo.WindowWidth;
|
||||
this.Height = ConfigManager.Config.DebugInfo.WindowHeight;
|
||||
if(ConfigManager.Config.DebugInfo.BottomPanelHeight > 0) {
|
||||
this.splitContainer.SplitterDistance = ConfigManager.Config.DebugInfo.BottomPanelHeight;
|
||||
}
|
||||
|
||||
_lastCodeWindow = ctrlDebuggerCode;
|
||||
|
||||
this.ctrlDebuggerCode.SetConfig(ConfigManager.Config.DebugInfo.LeftView);
|
||||
@ -416,6 +422,11 @@ namespace Mesen.GUI.Debugger
|
||||
|
||||
protected override void OnFormClosed(FormClosedEventArgs e)
|
||||
{
|
||||
ConfigManager.Config.DebugInfo.WindowWidth = this.Width;
|
||||
ConfigManager.Config.DebugInfo.WindowHeight = this.Height;
|
||||
ConfigManager.Config.DebugInfo.BottomPanelHeight = this.splitContainer.SplitterDistance;
|
||||
ConfigManager.ApplyChanges();
|
||||
|
||||
SaveWorkspace();
|
||||
|
||||
foreach(Form frm in this._childForms.ToArray()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user