Remove AsyncAppContext::remove_window
This commit is contained in:
@@ -411,10 +411,6 @@ impl AsyncAppContext {
|
||||
self.update(|cx| cx.add_window(window_options, build_root_view))
|
||||
}
|
||||
|
||||
pub fn remove_window(&mut self, window: AnyWindowHandle) {
|
||||
self.update_window(window, |cx| cx.remove_window());
|
||||
}
|
||||
|
||||
pub fn activate_window(&mut self, window: AnyWindowHandle) {
|
||||
self.update_window(window, |cx| cx.activate_window());
|
||||
}
|
||||
|
||||
@@ -1254,7 +1254,7 @@ impl Workspace {
|
||||
let prepare = self.prepare_to_close(false, cx);
|
||||
Some(cx.spawn(|_, mut cx| async move {
|
||||
if prepare.await? {
|
||||
cx.remove_window(window);
|
||||
window.remove(&mut cx);
|
||||
}
|
||||
Ok(())
|
||||
}))
|
||||
|
||||
Reference in New Issue
Block a user