Track state and forward events for logical keys.

Using physical key codes leads to unexpected bevahior on different
keyboard layouts. Use logical keys like SimpleGraphic.

Closes #27
This commit is contained in:
meehl committed 2026-03-05 08:30:56 +01:00
1 parent 966363a859
commit ef4f86eac8
6 files changed
+173 -225

No files matched your search

+3 -3
View File
@@ -1,14 +1,14 @@
use crate::{
app::AppState, installer::InstallMode, pob::PoBMode, renderer::primitives::ClippedPrimitive,
};
use winit::{event::MouseButton, keyboard::KeyCode};
use winit::{event::MouseButton, keyboard::Key};
pub enum AppEvent {
KeyDown {
code: KeyCode,
key: Key,
},
KeyUp {
code: KeyCode,
key: Key,
},
MouseDown {
button: MouseButton,