From 0b3c794cc950120147aeaec347db7ffef5ce37f6 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Fri, 29 Jun 2012 04:28:28 +0200 Subject: [PATCH] * Use new Querylabel API. --- src/libtomahawk/infobar/InfoBar.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/libtomahawk/infobar/InfoBar.cpp b/src/libtomahawk/infobar/InfoBar.cpp index 84f334658..e69e45c59 100644 --- a/src/libtomahawk/infobar/InfoBar.cpp +++ b/src/libtomahawk/infobar/InfoBar.cpp @@ -132,10 +132,11 @@ InfoBar::setDescription( const QString& s ) ui->descriptionLabel->setText( s ); } + void InfoBar::setDescription( const artist_ptr& artist ) { - m_queryLabel->setQuery( Query::get( artist->name(), QString(), QString() ) ); + m_queryLabel->setArtist( artist ); m_queryLabel->setExtraContentsMargins( 4, 0, 0, 0 ); if ( !m_queryLabel->isVisible() ) @@ -151,16 +152,17 @@ InfoBar::setDescription( const artist_ptr& artist ) } void -InfoBar::setDescription( const album_ptr& ) +InfoBar::setDescription( const album_ptr& ) { // TODO } + void InfoBar::artistClicked() { - if ( m_queryLabel && !m_queryLabel->query().isNull() ) - ViewManager::instance()->show( Artist::get( m_queryLabel->artist() ) ); + if ( m_queryLabel && !m_queryLabel->artist().isNull() ) + ViewManager::instance()->show( m_queryLabel->artist() ); } @@ -212,7 +214,6 @@ InfoBar::setUpdaters( const QList& updaters ) newUpdaterWidgets << updater->configurationWidget(); } - foreach ( QWidget* updaterWidget, m_updaterConfigurations ) { updaterWidget->hide();