keyboard: absolve release event if press was bound

When key press events are handled by compositor keybindings, do not
forward the corresponding release events to clients.
This commit is contained in:
Johan Malm 2021-12-21 22:25:59 +00:00 committed by ARDiDo
parent 57cc72b49e
commit 7e57b7fcf5
4 changed files with 99 additions and 0 deletions

10
include/key-state.h Normal file
View file

@ -0,0 +1,10 @@
/* SPDX-License-Identifier: GPL-2.0-only */
#ifndef __LABWC_KEY_STATE_H
#define __LABWC_KEY_STATE_H
void key_state_set_pressed(uint32_t keycode, bool ispressed);
void key_state_store_pressed_keys_as_bound(void);
bool key_state_corresponding_press_event_was_bound(uint32_t keycode);
void key_state_bound_key_remove(uint32_t keycode);
#endif /* __LABWC_KEY_STATE_H */