linput

Listen to input events
git clone git://git.akobets.xyz/linput
Log | Files | Refs | README | LICENSE

commit d0177ca7ad433a0e5c0a12d8a18a3439de88641b
parent 5ca1bb3f9dd3effadda5840bb7e281708b3f7ddc
Author: Artem Kobets <artem@akobets.xyz>
Date:   Sat, 18 Apr 2020 16:47:37 +0300

hotkey match optimizations

Diffstat:
Mlinput.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/linput.c b/linput.c @@ -156,13 +156,13 @@ is_hotkey_active(const struct HotkeyRule *hotkey, int last_key) int k; int match = 1; - if (!is_match_hotkey_mod(hotkey)) - match = 0; - if (!is_mod(last_key)) if (!has_key(hotkey, last_key)) match = 0; + if (!is_match_hotkey_mod(hotkey)) + match = 0; + if (!is_match_hotkey_event(hotkey, last_key)) match = 0;