Merge lp://qastaging/~bratsche/appmenu-gtk/parent-tracking into lp://qastaging/appmenu-gtk/0.4

Proposed by Cody Russell
Status: Merged
Merged at revision: 101
Proposed branch: lp://qastaging/~bratsche/appmenu-gtk/parent-tracking
Merge into: lp://qastaging/appmenu-gtk/0.4
Diff against target: 127 lines (+53/-8)
1 file modified
src/bridge.c (+53/-8)
To merge this branch: bzr merge lp://qastaging/~bratsche/appmenu-gtk/parent-tracking
Reviewer Review Type Date Requested Status
Ted Gould (community) Approve
Review via email: mp+37762@code.qastaging.launchpad.net

Description of the change

dbusmenu doesn't have a way to retrieve the parent menuitem of a child, but we need that in order to delete a child. So we'll use g_object_{set,get}_data() to track parents inside appmenu-gtk.

This fixes an issue with Nautilus's bookmark manager, where adding or removing a bookmark results in several copies of all the dynamic menuitems being added to that menu, and it keeps getting larger until Nautilus is restarted.

To post a comment you must log in.
Revision history for this message
Ted Gould (ted) wrote :

I'm trying to figure if we need a weak ref on the parent. I think that it's okay as you're not moving menuitems around to different parents anywhere else in appmenu-gtk. But, I think you should probably put a comment in for when something changes :)

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches