[Rhythmbox-devel] patch for playlists not syncing

Hi.  I use playlists quite a lot on my ipod, and I found rb 2.96 wasn't syncing them on ubuntu 12.04.

To reproduce: after creating a playlist within RB, right-click on the device, properties, sync.  When Music was checked, it implicitly checked all items under it (including playlists), but none of my playlists would exist on the ipod after it was unmounted.  The workaround I found was to uncheck Music, then manually check each playlist.  Tedious, but perhaps it's an option for folks who can't build RB from scratch, and happen to read this report before the fix is released.

I found that setting persisted in ~/.local/share/rhythmbox/sync/device-*.conf ; when "Music" is checked, then [music]/enabled is set to true and no playlist is mentioned by name; otherwise it's set to false & each selected playlist appears by name.  The old code would only sync a playlist if it was explicitly mentioned; the fix below adds checking if [music]/enabled is true.  Another solution might be to explicitly mention each playlist by name even if [music]/enabled is set to true, but I suspect what's below is cleaner.

I checked the source for 2.98; this section of code is unchanged between 2.96 & 2.98, so I'm guessing the problem exists there too, but I haven't tested it myself.

diff -rc rhythmbox-2.96.orig/sources/sync/rb-sync-settings.c rhythmbox-2.96/sources/sync/rb-sync-settings.c
*** rhythmbox-2.96.orig/sources/sync/rb-sync-settings.c Sat Feb 11 23:13:13 2012
--- rhythmbox-2.96/sources/sync/rb-sync-settings.c      Sun Dec 30 16:45:03 2012
*** 254,259 ****
--- 254,263 ----
        int i;
        gboolean found = FALSE;

+       if (rb_sync_settings_sync_category (settings, category) == TRUE) {
+               return TRUE;
+       }
        groups = g_key_file_get_string_list (priv->key_file, category, CATEGORY_GROUPS_KEY, NULL, NULL);
        if (groups == NULL) {
                return FALSE;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]