mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-20 07:49:42 +01:00
* Fixed XSPFLoader and SpotifyParser inits.
This commit is contained in:
parent
982202e77a
commit
fb83e31324
@ -606,13 +606,13 @@ DropJob::handleXspfs( const QString& fileUrls )
|
||||
|
||||
if ( xspfFile.exists() )
|
||||
{
|
||||
l = new XSPFLoader( dropAction() == Create, this );
|
||||
l = new XSPFLoader( dropAction() == Create, false, this );
|
||||
tDebug( LOGINFO ) << "Loading local XSPF" << xspfFile.fileName();
|
||||
l->load( xspfFile );
|
||||
}
|
||||
else if ( QUrl( url ).isValid() )
|
||||
{
|
||||
l = new XSPFLoader( dropAction() == Create, this );
|
||||
l = new XSPFLoader( dropAction() == Create, false, this );
|
||||
tDebug( LOGINFO ) << "Loading remote XSPF" << url;
|
||||
l->load( QUrl( url ) );
|
||||
}
|
||||
@ -741,7 +741,7 @@ DropJob::handleTrackUrls( const QString& urls )
|
||||
QStringList tracks = urls.split( QRegExp( "\\s+" ), QString::SkipEmptyParts );
|
||||
|
||||
tDebug() << "Got a list of spotify urls!" << tracks;
|
||||
SpotifyParser* spot = new SpotifyParser( tracks, this );
|
||||
SpotifyParser* spot = new SpotifyParser( tracks, false, this );
|
||||
connect( spot, SIGNAL( tracks( QList<Tomahawk::query_ptr> ) ), this, SLOT( onTracksAdded( QList< Tomahawk::query_ptr > ) ) );
|
||||
m_queryCount++;
|
||||
}
|
||||
|
@ -367,7 +367,7 @@ GlobalActionManager::parseTomahawkLink( const QString& urlIn )
|
||||
if ( urlHasQueryItem( u, "xspf" ) )
|
||||
{
|
||||
QUrl xspf = QUrl::fromUserInput( urlQueryItemValue( u, "xspf" ) );
|
||||
XSPFLoader* l = new XSPFLoader( true, this );
|
||||
XSPFLoader* l = new XSPFLoader( true, true, this );
|
||||
tDebug() << "Loading spiff:" << xspf.toString();
|
||||
l->load( xspf );
|
||||
connect( l, SIGNAL( ok( Tomahawk::playlist_ptr ) ), ViewManager::instance(), SLOT( show( Tomahawk::playlist_ptr ) ) );
|
||||
@ -533,7 +533,7 @@ GlobalActionManager::createPlaylistFromUrl( const QString& type, const QString &
|
||||
if ( type == "xspf" )
|
||||
{
|
||||
QUrl xspf = QUrl::fromUserInput( url );
|
||||
XSPFLoader* l= new XSPFLoader( true, this );
|
||||
XSPFLoader* l= new XSPFLoader( true, true, this );
|
||||
l->setOverrideTitle( title );
|
||||
l->load( xspf );
|
||||
connect( l, SIGNAL( ok( Tomahawk::playlist_ptr ) ), this, SLOT( playlistCreatedToShow( Tomahawk::playlist_ptr) ) );
|
||||
@ -1269,7 +1269,7 @@ GlobalActionManager::playSpotify( const QUrl& url )
|
||||
return false;
|
||||
|
||||
QString spotifyUrl = urlHasQueryItem( url, "spotifyURI" ) ? urlQueryItemValue( url, "spotifyURI" ) : urlQueryItemValue( url, "spotifyURL" );
|
||||
SpotifyParser* p = new SpotifyParser( spotifyUrl, this );
|
||||
SpotifyParser* p = new SpotifyParser( spotifyUrl, false, this );
|
||||
connect( p, SIGNAL( track( Tomahawk::query_ptr ) ), this, SLOT( playOrQueueNow( Tomahawk::query_ptr ) ) );
|
||||
|
||||
return true;
|
||||
@ -1345,7 +1345,7 @@ GlobalActionManager::waitingForResolved( bool /* success */ )
|
||||
bool
|
||||
GlobalActionManager::openSpotifyLink( const QString& link )
|
||||
{
|
||||
SpotifyParser* spot = new SpotifyParser( link, this );
|
||||
SpotifyParser* spot = new SpotifyParser( link, false, this );
|
||||
connect( spot, SIGNAL( track( Tomahawk::query_ptr ) ), this, SLOT( handleOpenTrack( Tomahawk::query_ptr ) ) );
|
||||
|
||||
return true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user