[gtk+] combobox: Handle NULLing the cellview on remove simpler
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] combobox: Handle NULLing the cellview on remove simpler
- Date: Fri, 31 Jul 2015 02:06:50 +0000 (UTC)
commit bbd9c5983211244ec5bc8fb0ecc0e67d9f8345a6
Author: Benjamin Otte <otte redhat com>
Date: Wed Jul 29 22:25:52 2015 +0200
combobox: Handle NULLing the cellview on remove simpler
gtk/gtkcombobox.c | 8 +-------
1 files changed, 1 insertions(+), 7 deletions(-)
---
diff --git a/gtk/gtkcombobox.c b/gtk/gtkcombobox.c
index 3c79f91..0f77a2d 100644
--- a/gtk/gtkcombobox.c
+++ b/gtk/gtkcombobox.c
@@ -1556,18 +1556,12 @@ gtk_combo_box_add (GtkContainer *container,
gtk_widget_unparent (priv->cell_view);
_gtk_bin_set_child (GTK_BIN (container), NULL);
gtk_widget_queue_resize (GTK_WIDGET (container));
+ priv->cell_view = NULL;
}
gtk_widget_set_parent (widget, GTK_WIDGET (container));
_gtk_bin_set_child (GTK_BIN (container), widget);
- if (priv->cell_view &&
- widget != priv->cell_view)
- {
- /* since the cell_view was unparented, it's gone now */
- priv->cell_view = NULL;
- }
-
if (priv->has_entry)
{
/* this flag is a hack to tell the entry to fill its allocation.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]