aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarco Trevisan (Treviño) <mail@3v1n0.net>2014-06-07 01:37:51 +0200
committerMarco Trevisan (Treviño) <mail@3v1n0.net>2014-06-07 01:37:51 +0200
commit8380d53d11677d06e0e7036e7a011118d00e5852 (patch)
treefffcb96852e53f6de1bd5cb0356e069670f809ac
parent5eb4df61d9630cbe0cda3bf0e5d1f81011939a46 (diff)
downloadlibdbusmenu-8380d53d11677d06e0e7036e7a011118d00e5852.tar.gz
libdbusmenu-8380d53d11677d06e0e7036e7a011118d00e5852.tar.bz2
libdbusmenu-8380d53d11677d06e0e7036e7a011118d00e5852.zip
Parser: make sure that the old dbus menuitem is disconnected from the widget before recreating it
When a dbus menuitem has to be recreated, we need to disconnect the widget from it, or the old one will be reused at next parsing cycle.
-rw-r--r--libdbusmenu-gtk/parser.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libdbusmenu-gtk/parser.c b/libdbusmenu-gtk/parser.c
index 461927f..cc83e18 100644
--- a/libdbusmenu-gtk/parser.c
+++ b/libdbusmenu-gtk/parser.c
@@ -987,6 +987,7 @@ recreate_menu_item (DbusmenuMenuitem * parent, DbusmenuMenuitem * child)
GtkWidget * menuitem = pdata->widget;
dbusmenu_menuitem_child_delete (parent, child);
+ disconnect_from_widget (menuitem);
RecurseContext recurse = {0};
recurse.toplevel = gtk_widget_get_toplevel(menuitem);