mirror of
https://github.com/emilk/egui.git
synced 2026-09-01 06:10:06 -04:00
winit: don't explicitly handle Cmd-Q and Alt-F4 (#881)
Closes https://github.com/emilk/egui/issues/877 Still a problem: https://github.com/rust-windowing/winit/issues/1998
This commit is contained in:
@@ -268,7 +268,8 @@ impl EpiIntegration {
|
||||
}
|
||||
|
||||
pub fn on_event(&mut self, event: &winit::event::WindowEvent<'_>) {
|
||||
self.quit |= self.egui_winit.is_quit_event(event);
|
||||
use winit::event::WindowEvent;
|
||||
self.quit |= matches!(event, WindowEvent::CloseRequested | WindowEvent::Destroyed);
|
||||
self.egui_winit.on_event(&self.egui_ctx, event);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user