Commit cb27c4b0 authored by William Jon McCann's avatar William Jon McCann

Place the search icon in the primary slot of the entry

Instead of using the secondary slot for both clear and search. This
Makes it possible to use the search icon for actions regardless of
whether text has been entered, makes it possible to use the primary
icon to indicate search status, allows us to indicate the purpose
of the entry even if text has been already entered.

https://bugzilla.gnome.org/show_bug.cgi?id=694990
parent 7667d166
......@@ -74,7 +74,7 @@ search_entry_changed_cb (GtkEntry *entry,
if (str == NULL || *str == '\0')
{
icon_name = "edit-find-symbolic";
icon_name = NULL;
active = FALSE;
}
else
......@@ -101,6 +101,12 @@ gtk_search_entry_init (GtkSearchEntry *entry)
g_signal_connect (entry, "icon-release",
G_CALLBACK (search_entry_clear_cb), NULL);
g_object_set (entry,
"primary-icon-name", "edit-find-symbolic",
"primary-icon-activatable", FALSE,
"primary-icon-sensitive", FALSE,
NULL);
search_entry_changed_cb (GTK_ENTRY (entry), NULL);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment