From 971ee50dfe76c732c4dc82283e9f35491a9f26b3 Mon Sep 17 00:00:00 2001 From: yggverse Date: Wed, 18 Dec 2024 08:36:51 +0200 Subject: [PATCH] show results on entry is not empty --- src/app/browser/window/tab/item/page/search/form.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/browser/window/tab/item/page/search/form.rs b/src/app/browser/window/tab/item/page/search/form.rs index e5f97d9f..2bdf1e95 100644 --- a/src/app/browser/window/tab/item/page/search/form.rs +++ b/src/app/browser/window/tab/item/page/search/form.rs @@ -57,13 +57,13 @@ impl Form { let result = result.clone(); let separator = separator.clone(); let subject = subject.clone(); - move |_| { + move |this| { let matches = find( subject.borrow().as_ref().unwrap(), // @TODO handle input.entry.text().as_str(), match_case.is_active(), ); - if !matches.is_empty() { + if !this.text().is_empty() && !matches.is_empty() { result.show(0, matches.len()); separator.set_visible(true); } else {