[rhythmbox] add album artist support to ipod plugin
- From: Christophe Fergeau <teuf src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rhythmbox] add album artist support to ipod plugin
- Date: Thu, 10 Jun 2010 10:20:24 +0000 (UTC)
commit fd44f9ba6a77ef28750d1d4eed98e617e380a826
Author: Christophe Fergeau <cfergeau mandriva com>
Date: Thu Jun 10 12:08:48 2010 +0200
add album artist support to ipod plugin
This reads/writes the new album artist and album artist sort name
from iPods.
plugins/ipod/rb-ipod-source.c | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/plugins/ipod/rb-ipod-source.c b/plugins/ipod/rb-ipod-source.c
index e41b696..735b6bb 100644
--- a/plugins/ipod/rb-ipod-source.c
+++ b/plugins/ipod/rb-ipod-source.c
@@ -562,10 +562,13 @@ create_ipod_song_from_entry (RhythmDBEntry *entry, guint64 filesize, const char
track->title = rhythmdb_entry_dup_string (entry, RHYTHMDB_PROP_TITLE);
track->album = rhythmdb_entry_dup_string (entry, RHYTHMDB_PROP_ALBUM);
track->artist = rhythmdb_entry_dup_string (entry, RHYTHMDB_PROP_ARTIST);
+ track->albumartist = rhythmdb_entry_dup_string (entry, RHYTHMDB_PROP_ALBUM_ARTIST);
track->sort_artist = rhythmdb_entry_dup_string (entry,
RHYTHMDB_PROP_ARTIST_SORTNAME);
track->sort_album = rhythmdb_entry_dup_string (entry,
RHYTHMDB_PROP_ALBUM_SORTNAME);
+ track->sort_albumartist = rhythmdb_entry_dup_string (entry,
+ RHYTHMDB_PROP_ALBUM_ARTIST_SORTNAME);
track->genre = rhythmdb_entry_dup_string (entry, RHYTHMDB_PROP_GENRE);
track->filetype = g_strdup (mimetype);
track->size = filesize;
@@ -770,6 +773,12 @@ add_ipod_song_to_db (RBiPodSource *source, RhythmDB *db, Itdb_Track *song)
entry_set_string_prop (RHYTHMDB (db), entry,
RHYTHMDB_PROP_ARTIST, song->artist);
+ if (song->albumartist != NULL) {
+ entry_set_string_prop (RHYTHMDB (db), entry,
+ RHYTHMDB_PROP_ALBUM_ARTIST,
+ song->albumartist);
+ }
+
if (song->sort_artist != NULL) {
entry_set_string_prop (RHYTHMDB (db), entry,
RHYTHMDB_PROP_ARTIST_SORTNAME,
@@ -782,6 +791,12 @@ add_ipod_song_to_db (RBiPodSource *source, RhythmDB *db, Itdb_Track *song)
song->sort_album);
}
+ if (song->sort_albumartist != NULL) {
+ entry_set_string_prop (RHYTHMDB (db), entry,
+ RHYTHMDB_PROP_ALBUM_ARTIST_SORTNAME,
+ song->sort_albumartist);
+ }
+
entry_set_string_prop (RHYTHMDB (db), entry,
RHYTHMDB_PROP_ALBUM, song->album);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]