summaryrefslogtreecommitdiff
path: root/src/managers/KeybindManager.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-08-26 19:19:34 +0200
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-08-26 19:19:34 +0200
commita648b452ddc64f1f9507f4f4ec995fb5c6764b9a (patch)
tree23a0760a7c1375a29aa2a53ab5f60d5918cfc12d /src/managers/KeybindManager.cpp
parentd53b0a649163102965033a4a63b05387ee85d9cf (diff)
fix internal keybinds
Diffstat (limited to 'src/managers/KeybindManager.cpp')
-rw-r--r--src/managers/KeybindManager.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp
index e725785b..7b4eb211 100644
--- a/src/managers/KeybindManager.cpp
+++ b/src/managers/KeybindManager.cpp
@@ -141,6 +141,10 @@ bool CKeybindManager::onKeyEvent(wlr_keyboard_key_event* e, SKeyboard* pKeyboard
const auto KEYCODE = e->keycode + 8; // Because to xkbcommon it's +8 from libinput
const xkb_keysym_t keysym = xkb_state_key_get_one_sym(m_pXKBTranslationState, KEYCODE);
+ const xkb_keysym_t internalKeysym = xkb_state_key_get_one_sym(wlr_keyboard_from_input_device(pKeyboard->keyboard)->xkb_state, KEYCODE);
+
+ if (handleInternalKeybinds(internalKeysym))
+ return true;
const auto MODS = g_pInputManager->accumulateModsFromAllKBs();
@@ -251,9 +255,6 @@ int repeatKeyHandler(void* data) {
bool CKeybindManager::handleKeybinds(const uint32_t& modmask, const std::string& key, const xkb_keysym_t& keysym, const int& keycode, bool pressed, uint32_t time) {
bool found = false;
- if (handleInternalKeybinds(keysym))
- return true;
-
if (g_pCompositor->m_sSeat.exclusiveClient)
Debug::log(LOG, "Keybind handling only locked (inhibitor)");