mirror of
https://github.com/hyprwm/Hyprland
synced 2024-12-23 04:09:49 +01:00
fix internal keybinds
This commit is contained in:
parent
d53b0a6491
commit
a648b452dd
1 changed files with 4 additions and 3 deletions
|
@ -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 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 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();
|
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 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;
|
bool found = false;
|
||||||
|
|
||||||
if (handleInternalKeybinds(keysym))
|
|
||||||
return true;
|
|
||||||
|
|
||||||
if (g_pCompositor->m_sSeat.exclusiveClient)
|
if (g_pCompositor->m_sSeat.exclusiveClient)
|
||||||
Debug::log(LOG, "Keybind handling only locked (inhibitor)");
|
Debug::log(LOG, "Keybind handling only locked (inhibitor)");
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue