Debugger: Hex Editor - Give keyboard focus to the hex editor when form is opened
This commit is contained in:
parent
32f5ece894
commit
1d03eb7859
2 changed files with 11 additions and 0 deletions
|
@ -68,6 +68,11 @@ namespace Mesen.GUI.Debugger.Controls
|
||||||
mnuViewInMemoryType.InitShortcut(this, nameof(DebuggerShortcutsConfig.MemoryViewer_ViewInMemoryType));
|
mnuViewInMemoryType.InitShortcut(this, nameof(DebuggerShortcutsConfig.MemoryViewer_ViewInMemoryType));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public new void Focus()
|
||||||
|
{
|
||||||
|
this.ctrlHexBox.Focus();
|
||||||
|
}
|
||||||
|
|
||||||
public byte[] GetData()
|
public byte[] GetData()
|
||||||
{
|
{
|
||||||
return this._byteProvider != null ? this._byteProvider.Bytes.ToArray() : new byte[0];
|
return this._byteProvider != null ? this._byteProvider.Bytes.ToArray() : new byte[0];
|
||||||
|
|
|
@ -99,6 +99,12 @@ namespace Mesen.GUI.Debugger
|
||||||
this.InitShortcuts();
|
this.InitShortcuts();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected override void OnShown(EventArgs e)
|
||||||
|
{
|
||||||
|
base.OnShown(e);
|
||||||
|
ctrlHexViewer.Focus();
|
||||||
|
}
|
||||||
|
|
||||||
protected override void OnFormClosing(FormClosingEventArgs e)
|
protected override void OnFormClosing(FormClosingEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnFormClosing(e);
|
base.OnFormClosing(e);
|
||||||
|
|
Loading…
Add table
Reference in a new issue