From 443432606eac8f4a975cbf7cc403c4701bb88e0d Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Wed, 17 Aug 2022 09:33:48 -0600 Subject: [PATCH] Fix focus regression in contact finder Co-Authored-By: Antonio Scandurra --- crates/contacts_panel/src/contact_finder.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/contacts_panel/src/contact_finder.rs b/crates/contacts_panel/src/contact_finder.rs index d7c096aaa9..1831c1ba72 100644 --- a/crates/contacts_panel/src/contact_finder.rs +++ b/crates/contacts_panel/src/contact_finder.rs @@ -43,7 +43,9 @@ impl View for ContactFinder { } fn on_focus_in(&mut self, _: AnyViewHandle, cx: &mut ViewContext) { - cx.focus(&self.picker); + if cx.is_self_focused() { + cx.focus(&self.picker); + } } }