Merge pull request #2608 from ibaryshnikov/haskell

added physical_key to KeyReleased event
This commit is contained in:
Héctor 2024-10-02 17:02:13 +02:00 committed by GitHub
commit 5ee82b2ef0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 0 deletions

View file

@ -36,6 +36,12 @@ pub enum Event {
/// The key released.
key: Key,
/// The key released with all keyboard modifiers applied, except Ctrl.
modified_key: Key,
/// The physical key released.
physical_key: key::Physical,
/// The location of the key.
location: Location,

View file

@ -262,6 +262,8 @@ pub fn window_event(
winit::event::ElementState::Released => {
keyboard::Event::KeyReleased {
key,
modified_key,
physical_key,
modifiers,
location,
}