Bugzilla – Bug 349604
main-menu doesn't handle labeled bookmarks
Last modified: 2008-03-08 00:34:20 UTC
Main Menu doesn't know about labeled bookamrks in the form of: file:///home/ivanz/Syberia%202%20Saves Syberia 2 Saves and will handle that as a whole URI.
Created attachment 188132 [details] Patch to fix the issue Attached a patch to fix the issue.
Created attachment 188137 [details] Updated patch
*** Bug 327451 has been marked as a duplicate of this bug. ***
Thanks for the patch! Now it just needs to actually use the label. After calling create_item(), I think you can just do g_bookmark_file_set_title (priv->store, uri, label + 1); Later, when update_items() runs, it will call g_bookmark_file_get_title() and retrieve the label that you set.
Created attachment 188153 [details] Updated patch This one sets the title.
Created attachment 188154 [details] Updated patch
Created attachment 188157 [details] Updated patch This final patch check for title changes in update_items so that the menu reflects the changes in real time. :) Should be ready to go upstream.
Created attachment 188159 [details] Updated patch This one will compare title names only for USER_DIRS. Should be better optimization-wise. Cheers.
Excellent, there's a test package with your patch here: http://download.opensuse.org/repositories/home:/federico-mena:/10.3/openSUSE_10.3/ I *think* you may be leaking "uri" in some cases, but I didn't look at the patch too closely :) Let's talk about it tomorrow.
For scott to push upstream.
Created attachment 192206 [details] updated patch to fix segfault Thanks for the patch - couple of fixes to it. Add a bookmark via nautilus and do not set a label initially. Then later if you edit that bookmark and add a label the patch will segfault in the strcmp in update_items as priv->items[i]->title is null If you delete an existing title the patch will not update the display as it exits the check because title is null If there is no title it needs to fall back and compare the uri for differences (for reordering which is not supported yet but will be) updated patch to fix this.
submitted to factory - v 0.9.9