mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-20 07:49:42 +01:00
* Properly get artists / albums when using external resolvers.
This commit is contained in:
parent
d3d29acf09
commit
5f1a2df610
@ -364,9 +364,9 @@ QtScriptResolver::parseResultVariantList( const QVariantList& reslist )
|
||||
QVariantMap m = rv.toMap();
|
||||
|
||||
Tomahawk::result_ptr rp = Tomahawk::Result::get( m.value( "url" ).toString() );
|
||||
Tomahawk::artist_ptr ap = Tomahawk::Artist::get( 0, m.value( "artist" ).toString() );
|
||||
Tomahawk::artist_ptr ap = Tomahawk::Artist::get( m.value( "artist" ).toString(), false );
|
||||
rp->setArtist( ap );
|
||||
rp->setAlbum( Tomahawk::Album::get( 0, m.value( "album" ).toString(), ap ) );
|
||||
rp->setAlbum( Tomahawk::Album::get( ap, m.value( "album" ).toString(), false ) );
|
||||
rp->setTrack( m.value( "track" ).toString() );
|
||||
rp->setBitrate( m.value( "bitrate" ).toUInt() );
|
||||
rp->setSize( m.value( "size" ).toUInt() );
|
||||
|
@ -236,9 +236,9 @@ ScriptResolver::handleMsg( const QByteArray& msg )
|
||||
qDebug() << "Found result:" << m;
|
||||
|
||||
Tomahawk::result_ptr rp = Tomahawk::Result::get( m.value( "url" ).toString() );
|
||||
Tomahawk::artist_ptr ap = Tomahawk::Artist::get( 0, m.value( "artist" ).toString() );
|
||||
Tomahawk::artist_ptr ap = Tomahawk::Artist::get( m.value( "artist" ).toString(), false );
|
||||
rp->setArtist( ap );
|
||||
rp->setAlbum( Tomahawk::Album::get( 0, m.value( "album" ).toString(), ap ) );
|
||||
rp->setAlbum( Tomahawk::Album::get( ap, m.value( "album" ).toString(), false ) );
|
||||
rp->setTrack( m.value( "track" ).toString() );
|
||||
rp->setDuration( m.value( "duration" ).toUInt() );
|
||||
rp->setBitrate( m.value( "bitrate" ).toUInt() );
|
||||
|
Loading…
x
Reference in New Issue
Block a user