Skip to content

Commit

Permalink
Fix broken numlock behavior
Browse files Browse the repository at this point in the history
libcosmic broke backwards compatibility in pop-os/libcosmic@0491c4b
Add comparison with modified_key to ensure only actual named keys
are processed as such.
  • Loading branch information
Nashenas88 authored and jackpot51 committed Jan 14, 2025
1 parent ea29bf9 commit 2584518
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/terminal_box.rs
Original file line number Diff line number Diff line change
Expand Up @@ -693,10 +693,11 @@ where
match event {
Event::Keyboard(KeyEvent::KeyPressed {
key: Key::Named(named),
modified_key: Key::Named(modified_named),
modifiers,
text,
..
}) if state.is_focused => {
}) if state.is_focused && named == modified_named => {
for key_bind in self.key_binds.keys() {
if key_bind.matches(modifiers, &Key::Named(named)) {
return Status::Captured;
Expand Down

0 comments on commit 2584518

Please sign in to comment.