mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-01 03:40:16 +02:00
* Fixed artist links for similar tracks.
This commit is contained in:
@@ -343,10 +343,13 @@ AlbumItemDelegate::editorEvent( QEvent* event, QAbstractItemModel* model, const
|
|||||||
else if ( event->type() == QEvent::MouseButtonRelease )
|
else if ( event->type() == QEvent::MouseButtonRelease )
|
||||||
{
|
{
|
||||||
AlbumItem* item = m_model->sourceModel()->itemFromIndex( m_model->mapToSource( index ) );
|
AlbumItem* item = m_model->sourceModel()->itemFromIndex( m_model->mapToSource( index ) );
|
||||||
if ( !item || item->album().isNull() || item->album()->artist().isNull() )
|
if ( !item )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
ViewManager::instance()->show( item->album()->artist() );
|
if ( !item->query().isNull() )
|
||||||
|
ViewManager::instance()->show( Tomahawk::Artist::get( item->query()->artist() ) );
|
||||||
|
else if ( !item->album().isNull() && !item->album()->artist().isNull() )
|
||||||
|
ViewManager::instance()->show( item->album()->artist() );
|
||||||
|
|
||||||
event->accept();
|
event->accept();
|
||||||
return true;
|
return true;
|
||||||
|
Reference in New Issue
Block a user