desktop: Pass focus events to the player
This commit is contained in:
parent
9a88496763
commit
599352093c
|
@ -235,6 +235,12 @@ impl App {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
WindowEvent::Focused(true) => {
|
||||||
|
self.player.handle_event(PlayerEvent::FocusGained);
|
||||||
|
}
|
||||||
|
WindowEvent::Focused(false) => {
|
||||||
|
self.player.handle_event(PlayerEvent::FocusLost);
|
||||||
|
}
|
||||||
WindowEvent::MouseInput { button, state, .. } => {
|
WindowEvent::MouseInput { button, state, .. } => {
|
||||||
if self.gui.borrow_mut().is_context_menu_visible() {
|
if self.gui.borrow_mut().is_context_menu_visible() {
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue