Skip to content

Commit

Permalink
added physical_key to KeyReleased event
Browse files Browse the repository at this point in the history
  • Loading branch information
ibaryshnikov committed Sep 26, 2024
1 parent 7554837 commit 8b34f99
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/src/keyboard/event.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ pub enum Event {
/// The key released.
key: Key,

/// The physical key released.
physical_key: key::Physical,

/// The location of the key.
location: Location,

Expand Down
1 change: 1 addition & 0 deletions winit/src/conversion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ pub fn window_event(
winit::event::ElementState::Released => {
keyboard::Event::KeyReleased {
key,
physical_key,
modifiers,
location,
}
Expand Down

0 comments on commit 8b34f99

Please sign in to comment.