From f24c226af839c8edba9f1a433f615c3a89fb5e90 Mon Sep 17 00:00:00 2001 From: brian tan Date: Mon, 3 Mar 2025 07:22:23 -0500 Subject: [PATCH] assistant_context_editor: Close menus on send (#25440) Closes #ISSUE Before: https://github.com/user-attachments/assets/e63b6207-0c80-4fd6-99c0-febe3d639ba1 After: https://github.com/user-attachments/assets/870f2c6d-9b7f-456d-a1e3-26e1c31b129d Release Notes: - N/A --- crates/assistant_context_editor/src/context_editor.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/assistant_context_editor/src/context_editor.rs b/crates/assistant_context_editor/src/context_editor.rs index d47b800536..02f2bc9837 100644 --- a/crates/assistant_context_editor/src/context_editor.rs +++ b/crates/assistant_context_editor/src/context_editor.rs @@ -336,10 +336,14 @@ impl ContextEditor { } fn assist(&mut self, _: &Assist, window: &mut Window, cx: &mut Context) { + self.slash_menu_handle.hide(cx); + self.language_model_selector_menu_handle.hide(cx); self.send_to_model(RequestType::Chat, window, cx); } fn edit(&mut self, _: &Edit, window: &mut Window, cx: &mut Context) { + self.slash_menu_handle.hide(cx); + self.language_model_selector_menu_handle.hide(cx); self.send_to_model(RequestType::SuggestEdits, window, cx); }