mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-01-11 01:25:35 +00:00
[Input] Do not hook FocusedChanged
This is handled by NativeWindowBase now.
This commit is contained in:
parent
8eae337d93
commit
c98b4ea178
|
@ -196,12 +196,6 @@ namespace OpenTK.Input
|
|||
KeyUp(this, e);
|
||||
}
|
||||
|
||||
internal void ClearKeys()
|
||||
{
|
||||
for (Key i = 0; i < Key.LastKey; i++)
|
||||
state[i] = false;
|
||||
}
|
||||
|
||||
#if false
|
||||
internal void SetKey(Key key, uint scancode, KeyModifiers mods, bool pressed)
|
||||
{
|
||||
|
|
|
@ -69,14 +69,6 @@ namespace OpenTK.Platform
|
|||
// Hook keyboard events
|
||||
window.KeyDown += keyboard.HandleKeyDown;
|
||||
window.KeyUp += keyboard.HandleKeyUp;
|
||||
|
||||
window.FocusedChanged += (sender, e) =>
|
||||
{
|
||||
if (!window.Focused)
|
||||
{
|
||||
keyboard.ClearKeys();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#region IInputDriver Members
|
||||
|
|
Loading…
Reference in a new issue