x11/wayland: unbreak key bindings when capslock or numlock are active
Treat these similarly to positional key modifiers, but handle them centrally to avoid broader issues with eg: interpreting ESC in the command palette.
This commit is contained in:
1 file changed
+3
@@ -307,6 +307,9 @@ impl super::TermWindow {
|
||||
is_down: bool,
|
||||
key_event: Option<&KeyEvent>,
|
||||
) -> bool {
|
||||
// We don't allow caps lock or num lock to influence key resolution at the GUI layer.
|
||||
let raw_modifiers = raw_modifiers - (Modifiers::CAPS_LOCK | Modifiers::NUM_LOCK);
|
||||
|
||||
if is_down && !leader_active {
|
||||
// Check to see if this key-press is the leader activating
|
||||
if let Some(duration) = self.input_map.is_leader(&keycode, raw_modifiers) {
|
||||
|
||||
Reference in new issue
Block a user