Add ModifiersChanged
to keyboard::Event
This commit is contained in:
parent
1bc69e7a8a
commit
78cb805fac
@ -28,4 +28,7 @@ pub enum Event {
|
||||
|
||||
/// A unicode character was received.
|
||||
CharacterReceived(char),
|
||||
|
||||
/// The keyboard modifiers have changed.
|
||||
ModifiersChanged(ModifiersState),
|
||||
}
|
||||
|
@ -92,6 +92,9 @@ pub fn window_event(
|
||||
}
|
||||
}
|
||||
})),
|
||||
WindowEvent::ModifiersChanged(new_modifiers) => Some(Event::Keyboard(
|
||||
keyboard::Event::ModifiersChanged(modifiers_state(*new_modifiers)),
|
||||
)),
|
||||
WindowEvent::HoveredFile(path) => {
|
||||
Some(Event::Window(window::Event::FileHovered(path.clone())))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user