Author: bnickel
Date: 2007-05-15 17:19:18 -0400 (Tue, 15 May 2007)
New Revision: 77441
Modified:
trunk/taglib-sharp/ChangeLog
trunk/taglib-sharp/examples/ReadFromUri.cs
trunk/taglib-sharp/src/TagLib/Ape/Tag.cs
trunk/taglib-sharp/src/TagLib/Asf/Tag.cs
trunk/taglib-sharp/src/TagLib/CombinedTag.cs
trunk/taglib-sharp/src/TagLib/Id3v2/Tag.cs
trunk/taglib-sharp/src/TagLib/Mpeg4/AppleTag.cs
trunk/taglib-sharp/src/TagLib/Ogg/GroupedComment.cs
trunk/taglib-sharp/src/TagLib/Ogg/XiphComment.cs
trunk/taglib-sharp/src/TagLib/Tag.cs
Log:
2007-05-15 Brian Nickel <[EMAIL PROTECTED]>
* src/TagLib/Id3v2/Tag.cs: Fix BPM storage.
* src/TagLib/Tag.cs:
* src/TagLib/CombinedTag.cs:
* src/TagLib/Riff/InfoTag.cs:
* src/TagLib/Ape/Tag.cs:
* src/TagLib/Asf/Tag.cs:
* src/TagLib/Mpeg4/AppleTag.cs:
* src/TagLib/Ogg/XiphComment.cs:
* src/TagLib/Ogg/GroupedComment.cs: Rename BPM to BeatsPerMinute.
* examples/ReadFromUri.cs: Push/Pop abstractor. Add new tags to output.
Modified: trunk/taglib-sharp/ChangeLog
===================================================================
--- trunk/taglib-sharp/ChangeLog 2007-05-15 21:18:50 UTC (rev 77440)
+++ trunk/taglib-sharp/ChangeLog 2007-05-15 21:19:18 UTC (rev 77441)
@@ -1,8 +1,21 @@
2007-05-15 Brian Nickel <[EMAIL PROTECTED]>
+ * src/TagLib/Id3v2/Tag.cs: Fix BPM storage.
* src/TagLib/Tag.cs:
* src/TagLib/CombinedTag.cs:
* src/TagLib/Riff/InfoTag.cs:
+ * src/TagLib/Ape/Tag.cs:
+ * src/TagLib/Asf/Tag.cs:
+ * src/TagLib/Mpeg4/AppleTag.cs:
+ * src/TagLib/Ogg/XiphComment.cs:
+ * src/TagLib/Ogg/GroupedComment.cs: Rename BPM to BeatsPerMinute.
+ * examples/ReadFromUri.cs: Push/Pop abstractor. Add new tags to output.
+
+2007-05-15 Brian Nickel <[EMAIL PROTECTED]>
+
+ * src/TagLib/Tag.cs:
+ * src/TagLib/CombinedTag.cs:
+ * src/TagLib/Riff/InfoTag.cs:
* src/TagLib/Id3v2/Tag.cs
* src/TagLib/Ape/Tag.cs:
* src/TagLib/Asf/Tag.cs:
Modified: trunk/taglib-sharp/examples/ReadFromUri.cs
===================================================================
--- trunk/taglib-sharp/examples/ReadFromUri.cs 2007-05-15 21:18:50 UTC (rev
77440)
+++ trunk/taglib-sharp/examples/ReadFromUri.cs 2007-05-15 21:19:18 UTC (rev
77441)
@@ -13,8 +13,7 @@
Gnome.Vfs.Vfs.Initialize();
- TagLib.File.SetFileAbstractionCreator(new
TagLib.File.FileAbstractionCreator(
- VfsFileAbstraction.CreateFile));
+ TagLib.File.PushFileAbstractionCreator(VfsFileAbstraction.CreateFile);
DateTime start = DateTime.Now;
int songs_read = 0;
@@ -44,13 +43,17 @@
continue;
}
+ Console.WriteLine("Grouping: " + file.Tag.Grouping);
Console.WriteLine("Title: " + file.Tag.Title);
Console.WriteLine("Artists: " + (file.Tag.AlbumArtists ==
null ? String.Empty : System.String.Join ("\n ",
file.Tag.AlbumArtists)));
Console.WriteLine("Performers: " + (file.Tag.Performers ==
null ? String.Empty : System.String.Join ("\n ",
file.Tag.Performers)));
Console.WriteLine("Composers: " + (file.Tag.Composers ==
null ? String.Empty : System.String.Join ("\n ",
file.Tag.Composers)));
+ Console.WriteLine("Conductor: " + file.Tag.Conductor);
Console.WriteLine("Album: " + file.Tag.Album);
Console.WriteLine("Comment: " + file.Tag.Comment);
+ Console.WriteLine("Copyright: " + file.Tag.Copyright);
Console.WriteLine("Genres: " + (file.Tag.Genres ==
null ? String.Empty : System.String.Join ("\n ", file.Tag.Genres)));
+ Console.WriteLine("BPM: " + file.Tag.BeatsPerMinute);
Console.WriteLine("Year: " + file.Tag.Year);
Console.WriteLine("Track: " + file.Tag.Track);
Console.WriteLine("TrackCount: " + file.Tag.TrackCount);
@@ -102,7 +105,8 @@
songs_read ++;
}
} finally {
- Gnome.Vfs.Vfs.Shutdown();
+ Gnome.Vfs.Vfs.Shutdown();
+ TagLib.File.PopFileAbstractionCreator();
}
DateTime end = DateTime.Now;
Modified: trunk/taglib-sharp/src/TagLib/Ape/Tag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Ape/Tag.cs 2007-05-15 21:18:50 UTC (rev
77440)
+++ trunk/taglib-sharp/src/TagLib/Ape/Tag.cs 2007-05-15 21:19:18 UTC (rev
77441)
@@ -385,7 +385,7 @@
}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
Modified: trunk/taglib-sharp/src/TagLib/Asf/Tag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Asf/Tag.cs 2007-05-15 21:18:50 UTC (rev
77440)
+++ trunk/taglib-sharp/src/TagLib/Asf/Tag.cs 2007-05-15 21:19:18 UTC (rev
77441)
@@ -306,7 +306,7 @@
set {SetDescriptorString (value, "WM/Conductor");}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
Modified: trunk/taglib-sharp/src/TagLib/CombinedTag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/CombinedTag.cs 2007-05-15 21:18:50 UTC
(rev 77440)
+++ trunk/taglib-sharp/src/TagLib/CombinedTag.cs 2007-05-15 21:19:18 UTC
(rev 77441)
@@ -331,21 +331,21 @@
}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
uint output = 0;
foreach (Tag tag in tags)
if (tag != null && output == 0)
- output = tag.BPM;
+ output = tag.BeatsPerMinute;
return output;
}
set
{
foreach (Tag tag in tags)
if (tag != null)
- tag.BPM = value;
+ tag.BeatsPerMinute = value;
}
}
Modified: trunk/taglib-sharp/src/TagLib/Id3v2/Tag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Id3v2/Tag.cs 2007-05-15 21:18:50 UTC (rev
77440)
+++ trunk/taglib-sharp/src/TagLib/Id3v2/Tag.cs 2007-05-15 21:19:18 UTC (rev
77441)
@@ -438,7 +438,7 @@
}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
@@ -451,7 +451,7 @@
}
set
{
- SetNumberFrame ("TBPM", BPM, 0);
+ SetNumberFrame ("TBPM", value, 0);
}
}
Modified: trunk/taglib-sharp/src/TagLib/Mpeg4/AppleTag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Mpeg4/AppleTag.cs 2007-05-15 21:18:50 UTC
(rev 77440)
+++ trunk/taglib-sharp/src/TagLib/Mpeg4/AppleTag.cs 2007-05-15 21:19:18 UTC
(rev 77441)
@@ -411,7 +411,7 @@
}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
Modified: trunk/taglib-sharp/src/TagLib/Ogg/GroupedComment.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Ogg/GroupedComment.cs 2007-05-15 21:18:50 UTC
(rev 77440)
+++ trunk/taglib-sharp/src/TagLib/Ogg/GroupedComment.cs 2007-05-15 21:19:18 UTC
(rev 77441)
@@ -295,19 +295,19 @@
}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
uint output = 0;
foreach (XiphComment tag in tags)
if (tag != null && output == 0)
- output = tag.BPM;
+ output = tag.BeatsPerMinute;
return output;
}
set
{
- tags [0].BPM = value;
+ tags [0].BeatsPerMinute = value;
}
}
Modified: trunk/taglib-sharp/src/TagLib/Ogg/XiphComment.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Ogg/XiphComment.cs 2007-05-15 21:18:50 UTC
(rev 77440)
+++ trunk/taglib-sharp/src/TagLib/Ogg/XiphComment.cs 2007-05-15 21:19:18 UTC
(rev 77441)
@@ -459,7 +459,7 @@
set {AddField ("GROUPING", value);}
}
- public override uint BPM
+ public override uint BeatsPerMinute
{
get
{
Modified: trunk/taglib-sharp/src/TagLib/Tag.cs
===================================================================
--- trunk/taglib-sharp/src/TagLib/Tag.cs 2007-05-15 21:18:50 UTC (rev
77440)
+++ trunk/taglib-sharp/src/TagLib/Tag.cs 2007-05-15 21:19:18 UTC (rev
77441)
@@ -40,7 +40,7 @@
public virtual uint DiscCount {get {return 0;} set {}}
public virtual string Lyrics {get {return null;} set {}}
public virtual string Grouping {get {return null;} set {}}
- public virtual uint BPM {get {return 0;} set {}}
+ public virtual uint BeatsPerMinute {get {return 0;} set {}}
public virtual string Conductor {get {return null;} set {}}
public virtual string Copyright {get {return null;} set {}}
@@ -81,7 +81,7 @@
(Comment == null || Comment.Trim () == String.Empty) &&
(Genres == null || Genres.Length == 0) &&
Year == 0 &&
- BPM == 0 &&
+ BeatsPerMinute == 0 &&
Track == 0 &&
TrackCount == 0 &&
Disc == 0 &&
@@ -115,8 +115,8 @@
target.Disc = source.Disc;
if (overwrite || target.DiscCount == 0)
target.DiscCount = source.DiscCount;
- if (overwrite || target.BPM == 0)
- target.BPM = source.BPM;
+ if (overwrite || target.BeatsPerMinute == 0)
+ target.BeatsPerMinute = source.BeatsPerMinute;
if (overwrite || target.Grouping == null || target.Grouping.Trim() ==
String.Empty)
target.Grouping = source.Grouping;
if (overwrite || target.Conductor == null || target.Conductor.Trim()
== String.Empty)
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches