From b3bfc2b464883453f74b95eb941ed533e4dad94a Mon Sep 17 00:00:00 2001 From: Leo Franchi Date: Sat, 15 Oct 2011 19:29:27 -0400 Subject: [PATCH] Fetch album covers if albums were added before model was attached to view --- .../infosystem/infoplugins/generic/chartsplugin.cpp | 3 +-- src/libtomahawk/playlist/albumview.cpp | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp b/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp index 392b80fa1..511b6d62f 100644 --- a/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp +++ b/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp @@ -211,7 +211,6 @@ ChartsPlugin::notInCacheSlot( uint requestId, QHash criteria, { case InfoChart: { - /// Fetch the chart, we need source and id QUrl url = QUrl( QString( CHART_URL "source/%1/chart/%2" ).arg( criteria["chart_source"] ).arg( criteria["chart_id"] ) ); qDebug() << Q_FUNC_INFO << "Getting chart url" << url; @@ -395,7 +394,7 @@ ChartsPlugin::chartReturned() setChartType( None ); - qDebug() << "Got chart returned!" << res; +// qDebug() << "Got chart returned!" << res; foreach ( QVariant chartR, chartResponse ) { QString title, artist, album; diff --git a/src/libtomahawk/playlist/albumview.cpp b/src/libtomahawk/playlist/albumview.cpp index bf09641b3..45099d6e8 100644 --- a/src/libtomahawk/playlist/albumview.cpp +++ b/src/libtomahawk/playlist/albumview.cpp @@ -105,6 +105,7 @@ AlbumView::setAlbumModel( AlbumModel* model ) connect( m_proxyModel, SIGNAL( rowsInserted( QModelIndex, int, int ) ), SLOT( onViewChanged() ) ); setAcceptDrops( false ); + onViewChanged(); // Fetch covers if albums were added to model before model was attached to view }