Fix crash when closing windows

This commit is contained in:
Nathan Sobo
2021-05-05 11:34:49 -06:00
parent f7d8b6b4c0
commit 3f844bc953
4 changed files with 42 additions and 1 deletions
+1
View File
@@ -59,6 +59,7 @@ pub trait Dispatcher: Send + Sync {
pub trait Window: WindowContext {
fn on_event(&mut self, callback: Box<dyn FnMut(Event)>);
fn on_resize(&mut self, callback: Box<dyn FnMut(&mut dyn WindowContext)>);
fn on_close(&mut self, callback: Box<dyn FnOnce()>);
}
pub trait WindowContext {