mirror of
https://github.com/Ryujinx/Opentk.git
synced 2024-12-23 03:25:28 +00:00
[Win] Do not create second WinMMJoystick instance
This commit is contained in:
parent
45df508f8f
commit
d0522f1073
|
@ -84,7 +84,7 @@ namespace OpenTK.Platform.Windows
|
|||
const ClassStyle DefaultClassStyle = ClassStyle.OwnDC;
|
||||
|
||||
// Used for IInputDriver implementation
|
||||
WinMMJoystick joystick_driver = new WinMMJoystick();
|
||||
IJoystickDriver joystick_driver = Factory.Default.CreateLegacyJoystickDriver();
|
||||
KeyboardDevice keyboard = new KeyboardDevice();
|
||||
MouseDevice mouse = new MouseDevice();
|
||||
IList<KeyboardDevice> keyboards = new List<KeyboardDevice>(1);
|
||||
|
@ -1403,7 +1403,8 @@ namespace OpenTK.Platform.Windows
|
|||
|
||||
public void Poll()
|
||||
{
|
||||
joystick_driver.Poll();
|
||||
if (joystick_driver is WinMMJoystick)
|
||||
(joystick_driver as WinMMJoystick).Poll();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
|
Loading…
Reference in a new issue