From 82db5dedfb40aa2dbc1320d0c29882c2015a553f Mon Sep 17 00:00:00 2001 From: apricotbucket28 <71973804+apricotbucket28@users.noreply.github.com> Date: Tue, 6 Aug 2024 05:13:26 -0300 Subject: [PATCH] terminal: Fix context menu keybindings flicker (#15771) Fixes https://github.com/zed-industries/zed/issues/15156 [Screencast_20240804_112659.webm](https://github.com/user-attachments/assets/d6d15e65-ece2-4342-b2ca-55e3737a4736) Release Notes: - N/A --- crates/terminal_view/src/terminal_view.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/terminal_view/src/terminal_view.rs b/crates/terminal_view/src/terminal_view.rs index a724d674da..27e5dd2481 100644 --- a/crates/terminal_view/src/terminal_view.rs +++ b/crates/terminal_view/src/terminal_view.rs @@ -211,7 +211,8 @@ impl TerminalView { cx: &mut ViewContext, ) { let context_menu = ContextMenu::build(cx, |menu, _| { - menu.action("New Terminal", Box::new(NewTerminal)) + menu.context(self.focus_handle.clone()) + .action("New Terminal", Box::new(NewTerminal)) .separator() .action("Copy", Box::new(Copy)) .action("Paste", Box::new(Paste))