[Xfce4-commits] <xfce4-panel:devel> Check if menu item should be hidden.
Nick Schermer
noreply at xfce.org
Fri Feb 19 09:18:01 CET 2010
Updating branch refs/heads/devel
to 820a35fe174cbd934b2cbc0a3366ad04983e2da3 (commit)
from 8140ce54f55aaa54e4b92862fd5e71a2b119bf66 (commit)
commit 820a35fe174cbd934b2cbc0a3366ad04983e2da3
Author: Nick Schermer <nick at xfce.org>
Date: Fri Feb 19 09:16:03 2010 +0100
Check if menu item should be hidden.
plugins/applicationsmenu/applicationsmenu.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/plugins/applicationsmenu/applicationsmenu.c b/plugins/applicationsmenu/applicationsmenu.c
index ccd16c6..a5aa2c7 100644
--- a/plugins/applicationsmenu/applicationsmenu.c
+++ b/plugins/applicationsmenu/applicationsmenu.c
@@ -699,12 +699,16 @@ applications_menu_plugin_menu_add (GtkWidget *gtk_menu,
elements = garcon_menu_get_elements (menu);
for (li = elements; li != NULL; li = li->next)
{
+ panel_return_val_if_fail (GARCON_IS_MENU_ELEMENT (li->data), FALSE);
if (GARCON_IS_MENU_ITEM (li->data))
{
+ if (!garcon_menu_element_get_visible (li->data))
+ continue;
+
name = NULL;
if (plugin->show_generic_names)
name = garcon_menu_item_get_generic_name (li->data);
- if (G_UNLIKELY (name == NULL))
+ if (name == NULL)
name = garcon_menu_item_get_name (li->data);
if (G_UNLIKELY (name == NULL))
continue;
More information about the Xfce4-commits
mailing list