aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx/Ui/KeyboardController.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Ryujinx/Ui/KeyboardController.cs')
-rw-r--r--Ryujinx/Ui/KeyboardController.cs12
1 files changed, 7 insertions, 5 deletions
diff --git a/Ryujinx/Ui/KeyboardController.cs b/Ryujinx/Ui/KeyboardController.cs
index efa7bf56..f52642e3 100644
--- a/Ryujinx/Ui/KeyboardController.cs
+++ b/Ryujinx/Ui/KeyboardController.cs
@@ -1,6 +1,7 @@
using System;
using OpenTK.Input;
using Ryujinx.Common.Configuration.Hid;
+using Ryujinx.Configuration;
using Ryujinx.HLE.HOS.Services.Hid;
namespace Ryujinx.Ui
@@ -91,20 +92,21 @@ namespace Ryujinx.Ui
return (dx, dy);
}
- public HotkeyButtons GetHotkeyButtons()
+ public static HotkeyButtons GetHotkeyButtons(KeyboardState keyboard)
{
- KeyboardState keyboard = GetKeyboardState(_config.Index);
-
HotkeyButtons buttons = 0;
- if (keyboard[(Key)_config.Hotkeys.ToggleVsync]) buttons |= HotkeyButtons.ToggleVSync;
+ if (keyboard[(Key)ConfigurationState.Instance.Hid.Hotkeys.Value.ToggleVsync])
+ {
+ buttons |= HotkeyButtons.ToggleVSync;
+ }
return buttons;
}
class KeyMappingEntry
{
- public Key TargetKey;
+ public Key TargetKey;
public byte Target;
}