ayatana-commits team mailing list archive
-
ayatana-commits team
-
Mailing list archive
-
Message #00866
[Branch ~dbusmenu-team/dbusmenu/trunk] Rev 69: Removing unnecissary ref
Merge authors:
Ted Gould (ted)
Related merge proposals:
https://code.launchpad.net/~ted/dbusmenu/menu-repeat-repeat-repeat/+merge/18922
proposed by: Ted Gould (ted)
review: Approve - Cody Russell (bratsche)
------------------------------------------------------------
revno: 69 [merge]
committer: Ted Gould <ted@xxxxxxxx>
branch nick: trunk
timestamp: Tue 2010-02-09 08:48:21 -0600
message:
Removing unnecissary ref
modified:
libdbusmenu-glib/client.c
--
lp:dbusmenu
https://code.launchpad.net/~dbusmenu-team/dbusmenu/trunk
Your team ayatana-commits is subscribed to branch lp:dbusmenu.
To unsubscribe from this branch go to https://code.launchpad.net/~dbusmenu-team/dbusmenu/trunk/+edit-subscription.
=== modified file 'libdbusmenu-glib/client.c'
--- libdbusmenu-glib/client.c 2010-02-05 18:48:48 +0000
+++ libdbusmenu-glib/client.c 2010-02-08 22:02:12 +0000
@@ -774,15 +774,14 @@
g_debug("Client signaling root changed.");
#endif
- /* Switch the root around */
- g_object_ref(priv->root);
- dbusmenu_menuitem_set_root(priv->root, TRUE);
-
+ /* If they are different, and there was an old root we must
+ clean up that old root */
if (oldroot != NULL) {
dbusmenu_menuitem_set_root(oldroot, FALSE);
g_object_unref(oldroot);
}
+ /* If the root changed we can signal that */
g_signal_emit(G_OBJECT(client), signals[ROOT_CHANGED], 0, priv->root, TRUE);
}