From d9f275895b16822f1c0ea626f3bc81203e38aed1 Mon Sep 17 00:00:00 2001 From: Federico Terzi Date: Sat, 10 Jul 2021 11:19:24 +0200 Subject: [PATCH] fix(detect): fix wrong handling of repeated key presses on Wayland --- espanso-detect/src/evdev/device.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/espanso-detect/src/evdev/device.rs b/espanso-detect/src/evdev/device.rs index df4ab9a..1879a1d 100644 --- a/espanso-detect/src/evdev/device.rs +++ b/espanso-detect/src/evdev/device.rs @@ -148,7 +148,7 @@ impl Device { let keycode: xkb_keycode_t = EVDEV_OFFSET as u32 + code as u32; let keymap = unsafe { xkb_state_get_keymap(self.get_state()) }; - if value == KEY_STATE_REPEAT && unsafe { xkb_keymap_key_repeats(keymap, keycode) } != 0 { + if value == KEY_STATE_REPEAT && unsafe { xkb_keymap_key_repeats(keymap, keycode) } == 0 { return None; }