[gtk/matthiasc/for-master: 16/16] shortcutswindow: Clear search entry on unmap
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/matthiasc/for-master: 16/16] shortcutswindow: Clear search entry on unmap
- Date: Sun, 2 Aug 2020 13:35:39 +0000 (UTC)
commit 888a65c1fbad4509a4674404bf591356246e42e4
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Aug 2 09:33:52 2020 -0400
shortcutswindow: Clear search entry on unmap
Otherwise, the search term will linger around until
somebody clicks the search button again.
Fixes: #2981
gtk/gtkshortcutswindow.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkshortcutswindow.c b/gtk/gtkshortcutswindow.c
index 2fede662eb..64add4c38f 100644
--- a/gtk/gtkshortcutswindow.c
+++ b/gtk/gtkshortcutswindow.c
@@ -740,8 +740,8 @@ gtk_shortcuts_window_unmap (GtkWidget *widget)
GtkShortcutsWindow *self = (GtkShortcutsWindow *)widget;
GtkShortcutsWindowPrivate *priv = gtk_shortcuts_window_get_instance_private (self);
- if (priv->search_bar)
- gtk_search_bar_set_search_mode (priv->search_bar, FALSE);
+ gtk_search_bar_set_search_mode (priv->search_bar, FALSE);
+ gtk_editable_set_text (GTK_EDITABLE (priv->search_entry), "");
GTK_WIDGET_CLASS (gtk_shortcuts_window_parent_class)->unmap (widget);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]