diff options
author | Michael Hasselmann <michaelh@openismus.com> | 2009-03-10 15:57:16 +0000 |
---|---|---|
committer | Murray Cumming <murrayc@src.gnome.org> | 2009-03-10 15:57:16 +0000 |
commit | 2f915bec2077fba49e0c0ebee925b9486b3862d6 (patch) | |
tree | 8b42484f7b0499da0f0028812610cb7f025daa2b /gtk/gtkcomboboxentry.c | |
parent | 4895771c0946027edaec61780015c9412d19a342 (diff) | |
download | gtk+-2f915bec2077fba49e0c0ebee925b9486b3862d6.tar.gz |
Fixed regression reported in bug #574059. (search button not available in
2009-03-04 Michael Hasselmann <michaelh@openismus.com>
* gtk/gtkcomboboxentry.c (gtk_combo_box_entry_contents_changed):
Fixed regression reported in bug #574059. (search button not available in
some cases.) The old implementation relied on bug #572478.
svn path=/trunk/; revision=22500
Diffstat (limited to 'gtk/gtkcomboboxentry.c')
-rw-r--r-- | gtk/gtkcomboboxentry.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/gtk/gtkcomboboxentry.c b/gtk/gtkcomboboxentry.c index ad56ad352d..93ae5aea01 100644 --- a/gtk/gtkcomboboxentry.c +++ b/gtk/gtkcomboboxentry.c @@ -291,13 +291,15 @@ gtk_combo_box_entry_contents_changed (GtkEntry *entry, { GtkComboBox *combo_box = GTK_COMBO_BOX (user_data); - g_signal_handlers_block_by_func (combo_box, - gtk_combo_box_entry_active_changed, - NULL); - gtk_combo_box_set_active (combo_box, -1); - g_signal_handlers_unblock_by_func (combo_box, - gtk_combo_box_entry_active_changed, - NULL); + /* + * Fixes regression reported in bug #574059. The old functionality relied on + * bug #572478. As a bugfix, we now emit the "changed" signal ourselves + * when the selection was already set to -1. + */ + if (gtk_combo_box_get_active(combo_box) == -1) + g_signal_emit_by_name (combo_box, "changed"); + else + gtk_combo_box_set_active (combo_box, -1); } /* public API */ |