diff options
-rw-r--r-- | debian/changelog | 7 | ||||
-rw-r--r-- | libdbusmenu-gtk/parser.c | 16 |
2 files changed, 16 insertions, 7 deletions
diff --git a/debian/changelog b/debian/changelog index 268e8a3..4d13c95 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +libdbusmenu (0.3.93-0ubuntu2~ted9) UNRELEASED; urgency=low + + * Upstream Merge + * Only activate at the top level + + -- Ted Gould <ted@ubuntu.com> Wed, 26 Jan 2011 16:28:02 -0600 + libdbusmenu (0.3.93-0ubuntu2~ted8) natty; urgency=low * Upstream Merge diff --git a/libdbusmenu-gtk/parser.c b/libdbusmenu-gtk/parser.c index 07da2b9..46d214a 100644 --- a/libdbusmenu-gtk/parser.c +++ b/libdbusmenu-gtk/parser.c @@ -119,15 +119,17 @@ parse_menu_structure_helper (GtkWidget * widget, RecurseContext * recurse) * * Note that this will not force menuitems in submenus to be updated as well. */ - GList *children = gtk_container_get_children (GTK_CONTAINER (widget)); + if (recurse->parent == NULL) { + GList *children = gtk_container_get_children (GTK_CONTAINER (widget)); - for (; children != NULL; children = children->next) { - gtk_menu_shell_activate_item (GTK_MENU_SHELL (widget), - children->data, - TRUE); - } + for (; children != NULL; children = children->next) { + gtk_menu_shell_activate_item (GTK_MENU_SHELL (widget), + children->data, + TRUE); + } - g_list_free (children); + g_list_free (children); + } if (recurse->parent == NULL) { recurse->parent = dbusmenu_menuitem_new(); |