mirror of
https://github.com/claunia/cuetools.net.git
synced 2025-12-16 18:14:25 +00:00
CUERipper: When ripping disc a second time without reloading,
album art was added to file twice
This commit is contained in:
@@ -176,6 +176,10 @@
|
|||||||
<Project>{8DD1E84B-0B03-4C0B-9B42-1E49F75E7CB1}</Project>
|
<Project>{8DD1E84B-0B03-4C0B-9B42-1E49F75E7CB1}</Project>
|
||||||
<Name>ProgressODoom</Name>
|
<Name>ProgressODoom</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\taglib-sharp\src\taglib-sharp.csproj">
|
||||||
|
<Project>{6B143A39-C7B2-4743-9917-92262C60E9A6}</Project>
|
||||||
|
<Name>taglib-sharp</Name>
|
||||||
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Include="Resources\musicbrainz.ico" />
|
<None Include="Resources\musicbrainz.ico" />
|
||||||
|
|||||||
@@ -477,11 +477,13 @@ namespace CUERipper
|
|||||||
bnComboBoxOutputFormat.Items.RemoveAt(OutputPathUseTemplates.Length + 10);
|
bnComboBoxOutputFormat.Items.RemoveAt(OutputPathUseTemplates.Length + 10);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cueSheet.AlbumArt.Clear();
|
||||||
if (currentAlbumArt >= 0 && currentAlbumArt < albumArt.Count)
|
if (currentAlbumArt >= 0 && currentAlbumArt < albumArt.Count)
|
||||||
{
|
{
|
||||||
data.selectedRelease.metadata.AlbumArt.Clear();
|
data.selectedRelease.metadata.AlbumArt.Clear();
|
||||||
data.selectedRelease.metadata.AlbumArt.Add(albumArt[currentAlbumArt].meta);
|
data.selectedRelease.metadata.AlbumArt.Add(albumArt[currentAlbumArt].meta);
|
||||||
cueSheet.AddAlbumArt(albumArt[currentAlbumArt].contents);
|
var blob = new TagLib.ByteVector(albumArt[currentAlbumArt].contents);
|
||||||
|
cueSheet.AlbumArt.Add(new TagLib.Picture(blob) { Type = TagLib.PictureType.FrontCover });
|
||||||
}
|
}
|
||||||
|
|
||||||
data.selectedRelease.metadata.Save();
|
data.selectedRelease.metadata.Save();
|
||||||
|
|||||||
@@ -2956,14 +2956,6 @@ namespace CUETools.Processor
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void AddAlbumArt(byte[] encoded)
|
|
||||||
{
|
|
||||||
var data = new TagLib.ByteVector(encoded);
|
|
||||||
var picture = new TagLib.Picture(data);
|
|
||||||
picture.Type = TagLib.PictureType.FrontCover;
|
|
||||||
_albumArt.Add(picture);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void ResizeAlbumArt()
|
public void ResizeAlbumArt()
|
||||||
{
|
{
|
||||||
if (_albumArt == null)
|
if (_albumArt == null)
|
||||||
|
|||||||
Reference in New Issue
Block a user