private void UpdateId3Tags()
{
// Load the song file
var song = SFile.Create(MainResource.AbsolutePath);
if (song == null)
return;
// Title
if (!String.IsNullOrEmpty(_title))
song.Tag.Title = _title;
// Artist (Performer and Album Artist)
if (!String.IsNullOrEmpty(_author))
{
var authorTag = new[] {_author};
song.Tag.Performers = authorTag;
song.Tag.AlbumArtists = authorTag;
}
// Genre
if (!String.IsNullOrEmpty(Genre))
song.Tag.Genres = new[] {Genre};
// Album Art
song.Tag.Pictures = new IPicture[] {new Picture(Extras[0].AbsolutePath)};
song.Save();
}