From d681aa7977c7ee8144600f8b837d09720ef62f4b Mon Sep 17 00:00:00 2001 From: Tristan Van Berkom Date: Thu, 30 Dec 2010 16:46:50 +0900 Subject: [PATCH] Fixed GtkComboBox to properly set tearoff state on delegate GtkTreeMenu. This breakage was also the cause of not correctly positioning the child menu over the selected item. --- gtk/gtkcombobox.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gtk/gtkcombobox.c b/gtk/gtkcombobox.c index 489c2b724a..1b480cfd9c 100644 --- a/gtk/gtkcombobox.c +++ b/gtk/gtkcombobox.c @@ -4796,6 +4796,11 @@ gtk_combo_box_set_add_tearoffs (GtkComboBox *combo_box, { combo_box->priv->add_tearoffs = add_tearoffs; gtk_combo_box_check_appearance (combo_box); + + if (GTK_IS_TREE_MENU (combo_box->priv->popup_widget)) + _gtk_tree_menu_set_tearoff (GTK_TREE_MENU (combo_box->priv->popup_widget), + combo_box->priv->add_tearoffs); + g_object_notify (G_OBJECT (combo_box), "add-tearoffs"); } }