From e9b162465957feac6a34e3a5501787cb9181c62a Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Mon, 16 Jun 2014 14:37:06 +0200 Subject: [PATCH] * Style fixes. --- src/libtomahawk/Playlist.cpp | 2 ++ src/libtomahawk/accounts/spotify/SpotifyAccount.cpp | 2 +- src/libtomahawk/playlist/TreeModel.cpp | 1 - src/libtomahawk/resolvers/JSResolver.cpp | 4 +++- src/libtomahawk/utils/TomahawkUtils.cpp | 1 + 5 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/libtomahawk/Playlist.cpp b/src/libtomahawk/Playlist.cpp index f6d5cfa45..f10a0e376 100644 --- a/src/libtomahawk/Playlist.cpp +++ b/src/libtomahawk/Playlist.cpp @@ -80,6 +80,7 @@ Playlist::Playlist( const source_ptr& author, init(); } + Playlist::Playlist( const source_ptr& author, const QString& guid, const QString& title, @@ -112,6 +113,7 @@ Playlist::~Playlist() delete d_ptr; } + QSharedPointer Playlist::removalHandler() { if ( s_removalHandler.isNull() ) diff --git a/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp b/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp index e93efdb2b..0347eb94f 100644 --- a/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp +++ b/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp @@ -231,7 +231,7 @@ SpotifyAccount::hookupResolver() m_spotifyResolver.data()->setIcon( TomahawkUtils::defaultPixmap( TomahawkUtils::SpotifyIcon ) ); connect( m_spotifyResolver.data(), SIGNAL( changed() ), this, SLOT( resolverChanged() ) ); - connect( m_spotifyResolver.data(), SIGNAL( customMessage( QString,QVariantMap ) ), this, SLOT( resolverMessage( QString, QVariantMap ) ) ); + connect( m_spotifyResolver.data(), SIGNAL( customMessage( QString, QVariantMap ) ), this, SLOT( resolverMessage( QString, QVariantMap ) ) ); connect( ActionCollection::instance(), SIGNAL( privacyModeChanged() ), SLOT( privateModeChanged() ) ); // Always get logged in status QVariantMap msg; diff --git a/src/libtomahawk/playlist/TreeModel.cpp b/src/libtomahawk/playlist/TreeModel.cpp index 2e4958e1d..7f9426362 100644 --- a/src/libtomahawk/playlist/TreeModel.cpp +++ b/src/libtomahawk/playlist/TreeModel.cpp @@ -262,7 +262,6 @@ TreeModel::addCollection( const collection_ptr& collection ) connect( collection.data(), SIGNAL( changed() ), SLOT( onCollectionChanged() ), Qt::UniqueConnection ); setIcon( collection->bigIcon() ); - setTitle( collection->prettyName() ); setDescription( collection->description() ); } diff --git a/src/libtomahawk/resolvers/JSResolver.cpp b/src/libtomahawk/resolvers/JSResolver.cpp index 1a8cb5144..b1da7f2b0 100644 --- a/src/libtomahawk/resolvers/JSResolver.cpp +++ b/src/libtomahawk/resolvers/JSResolver.cpp @@ -132,6 +132,7 @@ JSResolver::icon() const return d->icon; } + unsigned int JSResolver::weight() const { @@ -140,6 +141,7 @@ JSResolver::weight() const return d->weight; } + unsigned int JSResolver::timeout() const { @@ -239,7 +241,7 @@ JSResolver::init() } // add resolver dependencies, if any - foreach ( QString s, d->requiredScriptPaths ) + foreach ( const QString& s, d->requiredScriptPaths ) { QFile reqFile( s ); if( !reqFile.open( QIODevice::ReadOnly ) ) diff --git a/src/libtomahawk/utils/TomahawkUtils.cpp b/src/libtomahawk/utils/TomahawkUtils.cpp index 886ad88e5..0ad938675 100644 --- a/src/libtomahawk/utils/TomahawkUtils.cpp +++ b/src/libtomahawk/utils/TomahawkUtils.cpp @@ -906,6 +906,7 @@ urlSetQuery( QUrl& url, const QString& query ) #endif } + QByteArray percentEncode( const QUrl& url ) {