mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-06 14:16:32 +02:00
* Don't try to play unavailable results.
This commit is contained in:
@@ -487,6 +487,8 @@ AudioEngine::playItem( Tomahawk::PlaylistInterface* playlist, const Tomahawk::re
|
||||
{
|
||||
tDebug( LOGEXTRA ) << Q_FUNC_INFO << ( result.isNull() ? QString() : result->url() );
|
||||
|
||||
if ( !result->isOnline() )
|
||||
return;
|
||||
if ( !m_playlist.isNull() )
|
||||
m_playlist.data()->reset();
|
||||
|
||||
|
@@ -144,7 +144,7 @@ ArtistView::onItemActivated( const QModelIndex& index )
|
||||
ViewManager::instance()->show( item->artist() );
|
||||
else if ( !item->album().isNull() )
|
||||
ViewManager::instance()->show( item->album() );
|
||||
else if ( !item->result().isNull() )
|
||||
else if ( !item->result().isNull() && item->result()->isOnline() )
|
||||
{
|
||||
m_model->setCurrentItem( item->index );
|
||||
AudioEngine::instance()->playItem( m_proxyModel, item->result() );
|
||||
|
Reference in New Issue
Block a user