summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Alfredsen <loki_val@gentoo.org>2008-12-05 23:26:40 +0000
committerPeter Alfredsen <loki_val@gentoo.org>2008-12-05 23:26:40 +0000
commit47e62d37a161ca050819959978005f0269192657 (patch)
treedaee54ae68d8538803de69e8a7fd4df534a0200d /media-sound/banshee/files
parentVersion bump. (diff)
downloadgentoo-2-47e62d37a161ca050819959978005f0269192657.tar.gz
gentoo-2-47e62d37a161ca050819959978005f0269192657.tar.bz2
gentoo-2-47e62d37a161ca050819959978005f0269192657.zip
Fix metadata not being written to disk. http://bugzilla.gnome.org/563283. Author is thansen@freenode.
(Portage version: 2.2_rc16/cvs/Linux 2.6.28-rc6 x86_64)
Diffstat (limited to 'media-sound/banshee/files')
-rw-r--r--media-sound/banshee/files/banshee-1.4.1-metadata-writefail.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/media-sound/banshee/files/banshee-1.4.1-metadata-writefail.patch b/media-sound/banshee/files/banshee-1.4.1-metadata-writefail.patch
new file mode 100644
index 000000000000..b7f1c3b8eb2b
--- /dev/null
+++ b/media-sound/banshee/files/banshee-1.4.1-metadata-writefail.patch
@@ -0,0 +1,35 @@
+--- src/Core/Banshee.Core/Banshee.Streaming/StreamTagger.cs 2008-10-06 10:27:31.000000000 -0600
++++ src/Core/Banshee.Core/Banshee.Streaming/StreamTagger.cs.new 2008-12-05 16:01:22.513964625 -0700
+@@ -130,7 +130,7 @@
+ track.ArtistName = Choose (file.Tag.JoinedPerformers, track.ArtistName, preferTrackInfo);
+ track.AlbumTitle = Choose (file.Tag.Album, track.AlbumTitle, preferTrackInfo);
+ track.AlbumArtist = Choose (file.Tag.FirstAlbumArtist, track.AlbumArtist, preferTrackInfo);
+- track.IsCompilation = IsCompilation (file.Tag);
++ track.IsCompilation = IsCompilation (file);
+
+ track.TrackTitle = Choose (file.Tag.Title, track.TrackTitle, preferTrackInfo);
+ track.Genre = Choose (file.Tag.FirstGenre, track.Genre, preferTrackInfo);
+@@ -171,18 +171,18 @@
+ // TODO these ideas could also be done in an extension that collects such hacks
+ }
+
+- private static bool IsCompilation (TagLib.Tag tag)
++ private static bool IsCompilation (TagLib.File file)
+ {
+- TagLib.Id3v2.Tag id3v2_tag = tag as TagLib.Id3v2.Tag;
++ TagLib.Id3v2.Tag id3v2_tag = file.GetTag(TagLib.TagTypes.Id3v2, true) as TagLib.Id3v2.Tag;
+ if (id3v2_tag != null && id3v2_tag.IsCompilation)
+ return true;
+
+- TagLib.Mpeg4.AppleTag apple_tag = tag as TagLib.Mpeg4.AppleTag;
++ TagLib.Mpeg4.AppleTag apple_tag = file.GetTag(TagLib.TagTypes.Apple,true) as TagLib.Mpeg4.AppleTag;
+ if (apple_tag != null && apple_tag.IsCompilation)
+ return true;
+
+- if (tag.Performers.Length > 0 && tag.AlbumArtists.Length > 0 &&
+- (tag.Performers.Length != tag.AlbumArtists.Length || tag.FirstAlbumArtist != tag.FirstPerformer)) {
++ if (file.Tag.Performers.Length > 0 && file.Tag.AlbumArtists.Length > 0 &&
++ (file.Tag.Performers.Length != file.Tag.AlbumArtists.Length || file.Tag.FirstAlbumArtist != file.Tag.FirstPerformer)) {
+ return true;
+ }
+ return false;