[Xfce4-commits] <garcon:master> Do not decrement the internal refcount of items.

Jannis Pohlmann noreply at xfce.org
Sun Jun 26 23:38:02 CEST 2011


Updating branch refs/heads/master
         to 1d816daaaff26e7ee7bbfafa2aed9a38febb5c91 (commit)
       from e55762858aac06aa4d55a0cde3d1ede77ac97f45 (commit)

commit 1d816daaaff26e7ee7bbfafa2aed9a38febb5c91
Author: Jannis Pohlmann <jannis at xfce.org>
Date:   Sun Jun 26 23:31:12 2011 +0200

    Do not decrement the internal refcount of items.
    
    This reverts commit c63c7b91f1b9cca982a9441de5397d4019fa6fb0. The
    internal reference counter is used to check whether items are allocated
    or not. Whenever an item has been included in a menu at least once (that
    is, it matched an <Include> rule) it's refcount is not supposed to be
    lowered anymore (in that sense it's more like a boolean flag than a
    counter). Decrementing the refcount breaks <OnlyUnallocated/>.
    
    Reverting this change might break menu reloading, so perhaps we need to
    use something different than garcon_menu_item_unref() in
    XfceMenuItemCache. Will check later.

 garcon/garcon-menu-item.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/garcon/garcon-menu-item.c b/garcon/garcon-menu-item.c
index e49bbfe..5c5d2c4 100644
--- a/garcon/garcon-menu-item.c
+++ b/garcon/garcon-menu-item.c
@@ -1506,9 +1506,6 @@ garcon_menu_item_unref (GarconMenuItem *item)
 {
   g_return_if_fail (GARCON_IS_MENU_ITEM (item));
 
-  /* Decrement the allocation counter */
-  garcon_menu_item_decrement_allocated (item);
-
   /* Decrement the reference counter */
   g_object_unref (G_OBJECT (item));
 }



More information about the Xfce4-commits mailing list