srdusr
aboutsummaryrefslogtreecommitdiffstats
path: root/crates/wayland/src/udev/platform.rs
diff options
context:
space:
mode:
authorsrdusr <[email protected]>2024-07-14 01:02:00 +0200
committersrdusr <[email protected]>2024-07-14 01:02:00 +0200
commit2994f622b2998dc6aebbd38f52a6e6612ed8e7c8 (patch)
treeb181781f42cbbdf71551d09fdbc2a02d6c15d785 /crates/wayland/src/udev/platform.rs
parent86b557a6c0baa4146b30712d8b7633f1b9b46d43 (diff)
downloadsrdwm-2994f622b2998dc6aebbd38f52a6e6612ed8e7c8.tar.gz
srdwm-2994f622b2998dc6aebbd38f52a6e6612ed8e7c8.zip
Fix keybindings silently never firing when a named key is lowercase
canonicalize_key_combo already reordered multi-modifier combos into dispatch's canonical Ctrl/Shift/Alt/Mod4 order, but passed the key name through verbatim. keysyms::keysym_to_name capitalizes every named key ("Space", "Return", "Escape", "BackSpace", ...) while leaving letters/digits alone, so srd.bind("Super+space", ...) stored "Mod4+space" while a real Space keypress dispatches as "Mod4+Space" -- never matching. Accepted silently at config-load time, so the only live symptom was the bind's own callback never running at all. Root-caused live: keybindings.lua's Super+space bind had a temporary diagnostic added (logs to /tmp/superspace.log before spawning ags) to tell "key never fired" apart from "key fired but ags failed" - the log file never existed, meaning the callback itself never ran. Fix: round-trip the key name through name_to_keysym (already case- insensitive) and back through keysym_to_name before storing, so any case the config writes normalizes to dispatch's canonical form.
Diffstat (limited to 'crates/wayland/src/udev/platform.rs')
0 files changed, 0 insertions, 0 deletions