fix(wayland): keyboard input

This commit is contained in:
Nova
2023-10-01 01:35:04 -04:00
parent 4874f010dd
commit 1ac211c23f
5 changed files with 125 additions and 6 deletions

View File

@@ -86,6 +86,11 @@ impl KeyboardInfo {
0,
);
}
if pressed {
println!("Key {key} is being pressed with {state_components} modifiers");
} else {
println!("Key {key} is being released with {state_components} modifiers");
}
let wl_key_state = if pressed {
KeyState::Pressed

View File

@@ -1024,7 +1024,7 @@ impl Backend for XDGBackend {
&surface,
KeyboardEvent::Key {
key: key.abs() as u32,
state: key < 0,
state: key > 0,
},
);
}