From cb41db85965698dcf34217f8d26d9163a72a2e70 Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Tue, 15 Sep 2020 18:44:54 +0200 Subject: input: don’t use stale keycodes for arrow-up/down MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The keycodes will change if the seat’s keymap changes. Make sure we only do alternate scrolling if the seat has a keyboard, and use the *current* layout’s keycodes for arrow up/down (instead of the *first* layout’s). --- wayland.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'wayland.h') diff --git a/wayland.h b/wayland.h index 430d6b66..7d512ba0 100644 --- a/wayland.h +++ b/wayland.h @@ -149,6 +149,9 @@ struct seat { xkb_mod_index_t mod_ctrl; xkb_mod_index_t mod_meta; + xkb_keycode_t key_arrow_up; + xkb_keycode_t key_arrow_down; + /* Enabled modifiers */ bool shift; bool alt; -- cgit v1.3