Created
February 11, 2022 22:41
-
-
Save haselwarter/12680e428ea1c8a35670085591f3a618 to your computer and use it in GitHub Desktop.
Revisions
-
haselwarter created this gist
Feb 11, 2022 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,20 @@ commit 4167767b45324c70a0f30abbb95f7ac616558b7a Author: Philipp G. Haselwarter <philipp@haselwarter.org> Date: Fri Feb 11 23:38:00 2022 +0100 Bind ctrl-m (^M) to act like Return, i.e. accept the current entry diff --git a/wayland.c b/wayland.c index 4bf93be..3dda551 100644 --- a/wayland.c +++ b/wayland.c @@ -630,7 +630,8 @@ keyboard_key(void *data, struct wl_keyboard *wl_keyboard, uint32_t serial, } } - else if (sym == XKB_KEY_Return && effective_mods == 0) + else if ((sym == XKB_KEY_Return && effective_mods == 0) || + (sym == XKB_KEY_m && effective_mods == ctrl)) execute_selected(wayl); else if (effective_mods == 0) {