forked from AuroraMiddleware/gtk
Merge branch 'clear-search-entry' into 'master'
searchbar: Fix clearing search entry on hide See merge request GNOME/gtk!2820
This commit is contained in:
commit
1f9eb5c64c
@ -171,7 +171,7 @@ reveal_child_changed_cb (GObject *object,
|
|||||||
{
|
{
|
||||||
if (reveal_child && GTK_IS_ENTRY (bar->entry))
|
if (reveal_child && GTK_IS_ENTRY (bar->entry))
|
||||||
gtk_entry_grab_focus_without_selecting (GTK_ENTRY (bar->entry));
|
gtk_entry_grab_focus_without_selecting (GTK_ENTRY (bar->entry));
|
||||||
else if (GTK_IS_SEARCH_ENTRY (bar->entry))
|
else if (reveal_child && GTK_IS_SEARCH_ENTRY (bar->entry))
|
||||||
gtk_widget_grab_focus (bar->entry);
|
gtk_widget_grab_focus (bar->entry);
|
||||||
else
|
else
|
||||||
gtk_editable_set_text (GTK_EDITABLE (bar->entry), "");
|
gtk_editable_set_text (GTK_EDITABLE (bar->entry), "");
|
||||||
|
Loading…
Reference in New Issue
Block a user