diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2023-01-22 13:14:19 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-22 13:14:19 -0500 |
commit | ff2bbc82058a723e88109395fca74b6e283fad01 (patch) | |
tree | 12446c53f2c62e777f3d8c249c8171b8a69aa4ad /src/yuzu/hotkeys.cpp | |
parent | 02ac5932571d8a2c432d52af84dd353abd2ef2c2 (diff) | |
parent | 887ed5c0e2afa0fe4ef373ee676e197e62570e66 (diff) |
Merge pull request #9637 from SaiKai/repeat_shortcuts
allow volume up/down hotkeys to be repeated
Diffstat (limited to 'src/yuzu/hotkeys.cpp')
-rw-r--r-- | src/yuzu/hotkeys.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/yuzu/hotkeys.cpp b/src/yuzu/hotkeys.cpp index 13723f6e5..6530186c1 100644 --- a/src/yuzu/hotkeys.cpp +++ b/src/yuzu/hotkeys.cpp @@ -21,7 +21,7 @@ void HotkeyRegistry::SaveHotkeys() { {hotkey.first, group.first, UISettings::ContextualShortcut({hotkey.second.keyseq.toString(), hotkey.second.controller_keyseq, - hotkey.second.context})}); + hotkey.second.context, hotkey.second.repeat})}); } } } @@ -47,6 +47,7 @@ void HotkeyRegistry::LoadHotkeys() { hk.controller_shortcut->disconnect(); hk.controller_shortcut->SetKey(hk.controller_keyseq); } + hk.repeat = shortcut.shortcut.repeat; } } @@ -57,8 +58,7 @@ QShortcut* HotkeyRegistry::GetHotkey(const QString& group, const QString& action hk.shortcut = new QShortcut(hk.keyseq, widget, nullptr, nullptr, hk.context); } - hk.shortcut->setAutoRepeat(false); - + hk.shortcut->setAutoRepeat(hk.repeat); return hk.shortcut; } |