Use better name for the method that closes deleted buffers
co-authored-by: Max <max@zed.dev>
This commit is contained in:
parent
583b15badc
commit
2c8fffc4f8
2 changed files with 4 additions and 2 deletions
|
@ -1305,7 +1305,7 @@ impl Pane {
|
||||||
&self.toolbar
|
&self.toolbar
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn delete_item(
|
pub fn handle_deleted_project_item(
|
||||||
&mut self,
|
&mut self,
|
||||||
entry_id: ProjectEntryId,
|
entry_id: ProjectEntryId,
|
||||||
cx: &mut ViewContext<Pane>,
|
cx: &mut ViewContext<Pane>,
|
||||||
|
|
|
@ -539,7 +539,9 @@ impl Workspace {
|
||||||
|
|
||||||
project::Event::DeletedEntry(entry_id) => {
|
project::Event::DeletedEntry(entry_id) => {
|
||||||
for pane in this.panes.iter() {
|
for pane in this.panes.iter() {
|
||||||
pane.update(cx, |pane, cx| pane.delete_item(*entry_id, cx));
|
pane.update(cx, |pane, cx| {
|
||||||
|
pane.handle_deleted_project_item(*entry_id, cx)
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue