From 3de1ec8542de794e821fbdab29c7c6b34bd8fcf4 Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Sat, 18 Oct 2014 00:33:39 +0200 Subject: [PATCH] Modernize ScriptCcommands --- src/libtomahawk/resolvers/ScriptCommand_AllAlbums.h | 6 +++--- src/libtomahawk/resolvers/ScriptCommand_AllArtists.h | 10 +++++----- src/libtomahawk/resolvers/ScriptCommand_AllTracks.h | 6 +++--- src/libtomahawk/resolvers/ScriptCommand_LookupUrl.h | 10 ++++++---- 4 files changed, 17 insertions(+), 15 deletions(-) diff --git a/src/libtomahawk/resolvers/ScriptCommand_AllAlbums.h b/src/libtomahawk/resolvers/ScriptCommand_AllAlbums.h index 70473d9f0..13712e7cd 100644 --- a/src/libtomahawk/resolvers/ScriptCommand_AllAlbums.h +++ b/src/libtomahawk/resolvers/ScriptCommand_AllAlbums.h @@ -30,12 +30,12 @@ class ScriptCommand_AllAlbums : public ScriptCommand, public Tomahawk::AlbumsReq public: explicit ScriptCommand_AllAlbums( const Tomahawk::collection_ptr& collection, const Tomahawk::artist_ptr& artist, - QObject* parent = 0 ); + QObject* parent = nullptr ); virtual ~ScriptCommand_AllAlbums() {} - virtual void enqueue(); + void enqueue() override; - virtual void setFilter( const QString& filter ); + void setFilter( const QString& filter ) override; signals: void albums( const QList< Tomahawk::album_ptr >& ); diff --git a/src/libtomahawk/resolvers/ScriptCommand_AllArtists.h b/src/libtomahawk/resolvers/ScriptCommand_AllArtists.h index e3eaa4ac2..3020d355f 100644 --- a/src/libtomahawk/resolvers/ScriptCommand_AllArtists.h +++ b/src/libtomahawk/resolvers/ScriptCommand_AllArtists.h @@ -29,20 +29,20 @@ class ScriptCommand_AllArtists : public ScriptCommand, public Tomahawk::ArtistsR Q_OBJECT public: explicit ScriptCommand_AllArtists( const Tomahawk::collection_ptr& collection, - QObject* parent = 0 ); + QObject* parent = nullptr ); virtual ~ScriptCommand_AllArtists() {} - virtual void enqueue(); + void enqueue() override; - void setFilter( const QString& filter ); + void setFilter( const QString& filter ) override; signals: void artists( const QList< Tomahawk::artist_ptr >& ); void done(); protected: - virtual void exec(); - virtual void reportFailure(); + void exec() override; + void reportFailure() override; private slots: void onResolverDone( const QList< Tomahawk::artist_ptr >& ); diff --git a/src/libtomahawk/resolvers/ScriptCommand_AllTracks.h b/src/libtomahawk/resolvers/ScriptCommand_AllTracks.h index b1759efce..f7f9f5c9c 100644 --- a/src/libtomahawk/resolvers/ScriptCommand_AllTracks.h +++ b/src/libtomahawk/resolvers/ScriptCommand_AllTracks.h @@ -33,15 +33,15 @@ public: QObject *parent = 0 ); virtual ~ScriptCommand_AllTracks() {} - virtual void enqueue(); + void enqueue() override; signals: void tracks( const QList< Tomahawk::query_ptr >& ); void done(); protected: - virtual void exec(); - virtual void reportFailure(); + void exec() override; + void reportFailure() override; private slots: void onResolverDone( const QList< Tomahawk::query_ptr >& ); diff --git a/src/libtomahawk/resolvers/ScriptCommand_LookupUrl.h b/src/libtomahawk/resolvers/ScriptCommand_LookupUrl.h index a3ecf3ce9..04cc0513a 100644 --- a/src/libtomahawk/resolvers/ScriptCommand_LookupUrl.h +++ b/src/libtomahawk/resolvers/ScriptCommand_LookupUrl.h @@ -39,18 +39,20 @@ class DLLEXPORT ScriptCommand_LookupUrl : public ScriptCommand { Q_OBJECT public: - explicit ScriptCommand_LookupUrl( Tomahawk::ExternalResolver* resolver, const QString& url, QObject* parent = 0 ); + explicit ScriptCommand_LookupUrl( Tomahawk::ExternalResolver* resolver, + const QString& url, + QObject* parent = nullptr ); virtual ~ScriptCommand_LookupUrl(); - virtual void enqueue(); + void enqueue(); signals: void information( const QString& url, const QSharedPointer& variant ); void done(); protected: - virtual void exec(); - virtual void reportFailure(); + void exec() override; + void reportFailure() override; private slots: void onResolverDone( const QString& url, const QSharedPointer& information );