Permalink
Browse files

recentlyadded: use values from CAlbum instead of manually querying th…

…em one by one for every album
  • Loading branch information...
1 parent f95c66b commit 60ba8b124b79ba25ae2d0742ecd9d2075ea1cb9e @Montellese committed Jun 17, 2012
Showing with 3 additions and 3 deletions.
  1. +3 −3 xbmc/utils/RecentlyAddedJob.cpp
View
6 xbmc/utils/RecentlyAddedJob.cpp
@@ -291,10 +291,10 @@ bool CRecentlyAddedJob::UpdateMusic()
CStdString strArtist = musicdatabase.GetSingleValue("albumview", "strArtists", strSQLAlbum);
- home->SetProperty("LatestAlbum." + value + ".Title" , musicdatabase.GetAlbumById(album.idAlbum));
- home->SetProperty("LatestAlbum." + value + ".Year" , atoi(musicdatabase.GetSingleValue("album", "iYear", strSQLAlbum)));
+ home->SetProperty("LatestAlbum." + value + ".Title" , album.strAlbum);
+ home->SetProperty("LatestAlbum." + value + ".Year" , album.iYear);
home->SetProperty("LatestAlbum." + value + ".Artist" , strArtist);
- home->SetProperty("LatestAlbum." + value + ".Rating" , musicdatabase.GetSingleValue("albumview", "iRating", strSQLAlbum));
+ home->SetProperty("LatestAlbum." + value + ".Rating" , album.iRating);
home->SetProperty("LatestAlbum." + value + ".Path" , strDBpath);
home->SetProperty("LatestAlbum." + value + ".Thumb" , strThumb);
home->SetProperty("LatestAlbum." + value + ".Fanart" , strFanart);

0 comments on commit 60ba8b1

Please sign in to comment.