diff --git a/src/libtomahawk/playlist/treeitemdelegate.cpp b/src/libtomahawk/playlist/treeitemdelegate.cpp index e1cfc133f..0d1ac25ac 100644 --- a/src/libtomahawk/playlist/treeitemdelegate.cpp +++ b/src/libtomahawk/playlist/treeitemdelegate.cpp @@ -157,13 +157,13 @@ TreeItemDelegate::paint( QPainter* painter, const QStyleOptionViewItem& option, { if ( !item->album().isNull() ) { - m_pixmaps.insert( index, QSharedPointer< Tomahawk::PixmapDelegateFader >( new Tomahawk::PixmapDelegateFader( item->album(), r.size() ) ) ); + m_pixmaps.insert( index, QSharedPointer< Tomahawk::PixmapDelegateFader >( new Tomahawk::PixmapDelegateFader( item->album(), r.size(), false ) ) ); _detail::Closure* closure = NewClosure( m_pixmaps[ index ], SIGNAL( repaintRequest() ), const_cast(this), SLOT( doUpdateIndex( const QPersistentModelIndex& ) ), QPersistentModelIndex( index ) ); closure->setAutoDelete( false ); } else if ( !item->artist().isNull() ) { - m_pixmaps.insert( index, QSharedPointer< Tomahawk::PixmapDelegateFader >( new Tomahawk::PixmapDelegateFader( item->artist(), r.size() ) ) ); + m_pixmaps.insert( index, QSharedPointer< Tomahawk::PixmapDelegateFader >( new Tomahawk::PixmapDelegateFader( item->artist(), r.size(), false ) ) ); _detail::Closure* closure = NewClosure( m_pixmaps[ index ], SIGNAL( repaintRequest() ), const_cast(this), SLOT( doUpdateIndex( const QPersistentModelIndex& ) ), QPersistentModelIndex( index ) ); closure->setAutoDelete( false ); } diff --git a/src/libtomahawk/utils/PixmapDelegateFader.cpp b/src/libtomahawk/utils/PixmapDelegateFader.cpp index 34a6837ed..bdca50367 100644 --- a/src/libtomahawk/utils/PixmapDelegateFader.cpp +++ b/src/libtomahawk/utils/PixmapDelegateFader.cpp @@ -26,27 +26,27 @@ using namespace Tomahawk; #define COVER_FADEIN 1000 -PixmapDelegateFader::PixmapDelegateFader( const artist_ptr& artist, const QSize& size ) +PixmapDelegateFader::PixmapDelegateFader( const artist_ptr& artist, const QSize& size, bool forceLoad ) : m_artist( artist ) , m_size( size ) { if ( !m_artist.isNull() ) { connect( m_artist.data(), SIGNAL( coverChanged() ), this, SLOT( artistChanged() ) ); - m_currentReference = m_artist->cover( size ); + m_currentReference = m_artist->cover( size, forceLoad ); } init(); } -PixmapDelegateFader::PixmapDelegateFader( const album_ptr& album, const QSize& size ) +PixmapDelegateFader::PixmapDelegateFader( const album_ptr& album, const QSize& size, bool forceLoad ) : m_album( album ) , m_size( size ) { if ( !m_album.isNull() ) { connect( m_album.data(), SIGNAL( coverChanged() ), this, SLOT( albumChanged() ) ); - m_currentReference = m_album->cover( size ); + m_currentReference = m_album->cover( size, forceLoad ); } init(); diff --git a/src/libtomahawk/utils/PixmapDelegateFader.h b/src/libtomahawk/utils/PixmapDelegateFader.h index 3f6d32f14..65e963f70 100644 --- a/src/libtomahawk/utils/PixmapDelegateFader.h +++ b/src/libtomahawk/utils/PixmapDelegateFader.h @@ -39,8 +39,8 @@ class PixmapDelegateFader : public QObject { Q_OBJECT public: - PixmapDelegateFader( const artist_ptr& artist, const QSize& size ); - PixmapDelegateFader( const album_ptr& album, const QSize& size ); + PixmapDelegateFader( const artist_ptr& artist, const QSize& size, bool forceLoad = true ); + PixmapDelegateFader( const album_ptr& album, const QSize& size, bool forceLoad = true ); virtual ~PixmapDelegateFader();