1
0
mirror of https://github.com/strawberrymusicplayer/strawberry synced 2025-01-22 05:38:36 +01:00

Mpris2: Use art manual or automatic directly when available

Fixes #1079
This commit is contained in:
Jonas Kvinge 2022-12-10 23:22:46 +01:00
parent 3e7b51163c
commit 43c7934af7

View File

@ -401,6 +401,13 @@ void Mpris2::AlbumCoverLoaded(const Song &song, const AlbumCoverLoaderResult &re
else if (result.temp_cover_url.isValid() && result.temp_cover_url.isLocalFile()) {
cover_url = result.temp_cover_url;
}
else if (song.art_manual().isValid() && song.art_manual().isLocalFile() && song.art_manual().path() != Song::kManuallyUnsetCover && song.art_manual().path() != Song::kEmbeddedCover) {
cover_url = song.art_manual();
}
else if (song.art_automatic().isValid() && song.art_automatic().isLocalFile() && song.art_automatic().path() != Song::kManuallyUnsetCover && song.art_automatic().path() != Song::kEmbeddedCover) {
cover_url = song.art_automatic();
}
if (cover_url.isValid()) AddMetadata("mpris:artUrl", cover_url.toString(), &last_metadata_);
AddMetadata("year", song.year(), &last_metadata_);