When the file is deleted via project panel, close it in editors

This commit is contained in:
Kirill Bulatov 2023-05-19 18:04:12 +03:00
parent 3984cc6d39
commit 583b15badc
5 changed files with 222 additions and 1 deletions

View file

@ -537,6 +537,12 @@ impl Workspace {
cx.remove_window();
}
project::Event::DeletedEntry(entry_id) => {
for pane in this.panes.iter() {
pane.update(cx, |pane, cx| pane.delete_item(*entry_id, cx));
}
}
_ => {}
}
cx.notify()