diff options
Diffstat (limited to 'gtk/gtkoptionmenu.c')
-rw-r--r-- | gtk/gtkoptionmenu.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/gtk/gtkoptionmenu.c b/gtk/gtkoptionmenu.c index 2f45a59507..443a3f4a63 100644 --- a/gtk/gtkoptionmenu.c +++ b/gtk/gtkoptionmenu.c @@ -295,7 +295,12 @@ gtk_option_menu_remove_menu (GtkOptionMenu *option_menu) g_return_if_fail (GTK_IS_OPTION_MENU (option_menu)); if (option_menu->menu) - gtk_menu_detach (GTK_MENU (option_menu->menu)); + { + if (GTK_MENU_SHELL (option_menu->menu)->active) + g_signal_emit_by_name (option_menu->menu, "cancel", 0); + + gtk_menu_detach (GTK_MENU (option_menu->menu)); + } } void |