mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-27 15:13:13 -04:00
Add Occluded and MemoryWarning events for iOS/Android
Hook `Occluded` event to foreground/background evens on iOS. This commit also enabled the `MemoryWarning` event, since it's emitted from the windowing system. Co-authored-by: Dusty DeWeese <dustin.deweese@gmail.com> Co-authored-by: Kirill Chibisov <contact@kchibisov.com>
This commit is contained in:
committed by
Kirill Chibisov
parent
976023bfc0
commit
5788319632
@@ -272,10 +272,7 @@ impl<T: 'static> EventLoop<T> {
|
||||
}
|
||||
}
|
||||
MainEvent::LowMemory => {
|
||||
// XXX: how to forward this state to applications?
|
||||
// It seems like ideally winit should support lifecycle and
|
||||
// low-memory events, especially for mobile platforms.
|
||||
warn!("TODO: handle Android LowMemory notification");
|
||||
callback(event::Event::MemoryWarning, self.window_target());
|
||||
}
|
||||
MainEvent::Start => {
|
||||
// XXX: how to forward this state to applications?
|
||||
|
||||
Reference in New Issue
Block a user