diff --git a/src/main.rs b/src/main.rs index 3a0f237..b5a3f60 100644 --- a/src/main.rs +++ b/src/main.rs @@ -493,6 +493,9 @@ impl ApplicationHandler for App<'_> { self.windows.insert(window_id, window_ctx); } } + fn suspended(&mut self, _event_loop: &ActiveEventLoop) { + self.windows.clear(); + } } pub fn main() -> Result<(), terminator::Terminator> { let config = LoggerConfig::default() @@ -507,6 +510,10 @@ pub fn main() -> Result<(), terminator::Terminator> { { _main() } + #[cfg(target_os = "android")] + { + Ok(()) + } } pub fn run_app(event_loop: winit::event_loop::EventLoop<()>) -> Result<(), terminator::Terminator> { let mut app = App::new();