From 9ed2dc45c493d245f9bdcf9d3afb9c7fe1885325 Mon Sep 17 00:00:00 2001 From: Mattias Eriksson Date: Wed, 17 Jan 2024 16:48:15 +0100 Subject: [PATCH] Re-focus teminal after context drawer is closed --- src/main.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main.rs b/src/main.rs index 1e1e096..54ce6e2 100644 --- a/src/main.rs +++ b/src/main.rs @@ -776,6 +776,14 @@ impl Application for App { self.update_focus() } + fn on_context_drawer(&mut self) -> Command { + if !self.core.window.show_context { + self.update_focus() + } else { + Command::none() + } + } + /// Handle application events here. fn update(&mut self, message: Self::Message) -> Command { match message {