1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-15 02:24:50 +02:00

Pass filter to artists() in script collection

This commit is contained in:
Dominik Schmidt
2015-04-07 00:50:47 +02:00
committed by Christian Muehlhaeuser
parent 0b657bbce4
commit e519637546

View File

@@ -64,7 +64,13 @@ ScriptCommand_AllArtists::exec()
Tomahawk::ScriptCollection* collection = qobject_cast< Tomahawk::ScriptCollection* >( m_collection.data() );
Q_ASSERT( collection );
ScriptJob* job = collection->scriptObject()->invoke( "artists" );
QVariantMap arguments;
if ( !m_filter.isEmpty() )
{
arguments[ "filter" ] = m_filter;
}
ScriptJob* job = collection->scriptObject()->invoke( "artists", arguments );
connect( job, SIGNAL( done( QVariantMap ) ), SLOT( onArtistsJobDone( QVariantMap ) ), Qt::QueuedConnection );
job->start();
}