agent: Make directory context display update on rename (#29189)
Release Notes: - N/A
This commit is contained in:
parent
c15382c4d8
commit
2e8ee9b64f
5 changed files with 74 additions and 31 deletions
|
@ -3282,12 +3282,10 @@ pub(crate) fn open_context(
|
|||
}
|
||||
}
|
||||
AssistantContext::Directory(directory_context) => {
|
||||
let project_path = directory_context.project_path(cx);
|
||||
let entry_id = directory_context.entry_id;
|
||||
workspace.update(cx, |workspace, cx| {
|
||||
workspace.project().update(cx, |project, cx| {
|
||||
if let Some(entry) = project.entry_for_path(&project_path, cx) {
|
||||
cx.emit(project::Event::RevealInProjectPanel(entry.id));
|
||||
}
|
||||
workspace.project().update(cx, |_project, cx| {
|
||||
cx.emit(project::Event::RevealInProjectPanel(entry_id));
|
||||
})
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue