InputWidget now clears on Escape
This commit is contained in:
parent
1a00047b7e
commit
bb10d36b73
|
@ -32,12 +32,20 @@ namespace BizHawk.MultiClient
|
||||||
if (e.KeyCode == Keys.ControlKey) return;
|
if (e.KeyCode == Keys.ControlKey) return;
|
||||||
if (e.KeyCode == Keys.ShiftKey) return;
|
if (e.KeyCode == Keys.ShiftKey) return;
|
||||||
if (e.KeyCode == Keys.Menu) return;
|
if (e.KeyCode == Keys.Menu) return;
|
||||||
KeyboardBinding kb = new KeyboardBinding();
|
if (e.KeyCode != Keys.Escape)
|
||||||
kb.key = e.KeyCode;
|
{
|
||||||
kb.modifiers = e.Modifiers;
|
KeyboardBinding kb = new KeyboardBinding();
|
||||||
Bindings.Clear();
|
kb.key = e.KeyCode;
|
||||||
Bindings.Add(kb);
|
kb.modifiers = e.Modifiers;
|
||||||
UpdateLabel();
|
Bindings.Clear();
|
||||||
|
Bindings.Add(kb);
|
||||||
|
UpdateLabel();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Bindings.Clear();
|
||||||
|
UpdateLabel();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void OnKeyPress(KeyPressEventArgs e)
|
protected override void OnKeyPress(KeyPressEventArgs e)
|
||||||
|
|
Loading…
Reference in New Issue