Esempio n. 1
0
void
CurrentEngine::metadataChanged( Meta::AlbumPtr album )
{
    QImage cover = album->image( m_coverWidth );
    qint64 coverCacheKey = cover.cacheKey();
    if( m_coverCacheKey != coverCacheKey )
    {
        m_coverCacheKey = coverCacheKey;
        setData( "current", "albumart", cover );
    }
}
Esempio n. 2
0
QPixmap PlainImageLoader::GetPixmap(Meta::AlbumPtr iAlbum)
{
    QPixmap pixmap;
    if ( iAlbum->hasImage() )
    {
		pixmap = QPixmap::fromImage(iAlbum->image());
    }
    else
    {
        pixmap = QPixmap( KStandardDirs::locate( "data", "amarok/images/blingdefaultcover.png" ) );
    }
	return pixmap;
}