[Rhythmbox-devel] [Weekly Report] Rhythmbox iPod/MTP Sync



This last week I have been laying out and designing how the syncing mechanism will work. Thus far, I've done most of my design work on the iPod plugin. I started with a top-down design procedure, laying out the necessary functions. Any input on this planned process is greatly appreciated. The plan for syncing, so far, is thus: - The Playlists and Podcasts selected for syncing are added to a PC-side file (Saved to file, so we can associate it with the iPod by UUID) - This file is then used as an "itinerary" of what the Device *should* look like. - The itinerary is compared with the Device's current state (by hashing it for comparison, see: http://cgit.freedesktop.org/~teuf/libgpod/commit/?id=21d6be328508918a7623609e676b7ed9ad53659a) - Two GLists of files are built up (one needing removal, one needing addition) - The size of the GLists are compared with the free-space on the device. sizeof(files_to_add) - sizeof(files_to_remove) < sizeof(device). If it fails this check then we abort the Sync, and throw up an error dialog. - The files needing to be removed from the Device are removed (Done first to free up space, if necessary)
 - The files needing to be added to the Device are added.

This last week, I also created a mostly empty new GObject called RBMediaPlayerSource, located between RBRemovableMediaSource and RBiPodSource/RBMtpSource. This Object will hopefully have the Sync functions and other shared code moved up from the iPod and MTP plugins (where possible). It was a big learning experience for me creating my first GObject, and Christophe was a great help, pointing out resources for me to refer to. It took several tries to get the GObject built successfully (and for it not to break everything), but I finally feel like I have a better understanding of GObjects (though, admittedly, I have a lot to learn about them).

The next few days ahead are college finals for me, so I will be putting my project on hold until Thursday, when I will begin implementing the Syncing functions.

Paul Bellamy


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