Prevent key release bindings running when session locked

This commit is contained in:
Simon Long 2024-04-26 15:36:02 +01:00
parent 8c6379cb59
commit 522897d5af

View file

@ -410,6 +410,11 @@ handle_compositor_keybindings(struct keyboard *keyboard,
if (event->state == WL_KEYBOARD_KEY_STATE_RELEASED) {
if (cur_keybind && cur_keybind->mod_only) {
if (seat->active_client_while_inhibited
|| seat->server->session_lock) {
cur_keybind = NULL;
return false;
}
key_state_store_pressed_key_as_bound(event->keycode);
actions_run(NULL, server, &cur_keybind->actions, 0);
cur_keybind = NULL;