From bcfa34357b3472d250090fc8cfe04d72a45d0047 Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Wed, 9 Jul 2014 23:22:28 +0200 Subject: [PATCH] Add Q_DECL_OVERRIDE for all function that are overriding something This was made automatically with clang-modernize -override-macros -add-override --- .../QProgressIndicator/QProgressIndicator.h | 8 ++--- src/3rdparty/fancylineedit/fancylineedit.cpp | 2 +- src/3rdparty/fancylineedit/fancylineedit.h | 4 +-- .../qtsingleapplication/qtsingleapplication.h | 2 +- src/creds/dummycredentials.h | 22 +++++++------- src/creds/httpcredentials.cpp | 2 +- src/creds/httpcredentials.h | 22 +++++++------- src/creds/shibboleth/shibbolethuserjob.h | 4 +-- src/creds/shibboleth/shibbolethwebview.h | 2 +- src/creds/shibbolethcredentials.h | 24 +++++++-------- src/mirall/cookiejar.h | 6 ++-- src/mirall/folderstatusmodel.h | 10 +++---- src/mirall/folderwizard.h | 12 ++++---- src/mirall/logbrowser.h | 2 +- src/mirall/mirallaccessmanager.h | 2 +- src/mirall/networkjobs.h | 30 +++++++++---------- src/mirall/owncloudpropagator.h | 6 ++-- src/mirall/owncloudsetupwizard.h | 8 ++--- src/mirall/owncloudtheme.h | 20 ++++++------- src/mirall/propagator_legacy.h | 4 +-- src/mirall/propagator_qnam.cpp | 14 ++++----- src/mirall/propagator_qnam.h | 20 ++++++------- src/mirall/propagatorjobs.h | 14 ++++----- src/mirall/settingsdialog.h | 4 +-- src/mirall/sslerrordialog.h | 2 +- src/owncloudcmd/simplesslerrorhandler.h | 2 +- src/updater/ocupdater.h | 12 ++++---- src/updater/sparkleupdater.h | 6 ++-- src/wizard/abstractcredswizardpage.h | 2 +- src/wizard/owncloudadvancedsetuppage.h | 8 ++--- src/wizard/owncloudhttpcredspage.h | 10 +++---- src/wizard/owncloudsetuppage.h | 8 ++--- src/wizard/owncloudshibbolethcredspage.h | 8 ++--- src/wizard/owncloudwizardresultpage.h | 4 +-- 34 files changed, 153 insertions(+), 153 deletions(-) diff --git a/src/3rdparty/QProgressIndicator/QProgressIndicator.h b/src/3rdparty/QProgressIndicator/QProgressIndicator.h index 0614da60d..ec81fb72b 100644 --- a/src/3rdparty/QProgressIndicator/QProgressIndicator.h +++ b/src/3rdparty/QProgressIndicator/QProgressIndicator.h @@ -64,8 +64,8 @@ public: */ const QColor & color() const { return m_color; } - virtual QSize sizeHint() const; - int heightForWidth(int w) const; + virtual QSize sizeHint() const Q_DECL_OVERRIDE; + int heightForWidth(int w) const Q_DECL_OVERRIDE; public slots: /*! Starts the spin animation. \sa stopAnimation isAnimated @@ -95,8 +95,8 @@ public slots: */ void setColor(const QColor & color); protected: - virtual void timerEvent(QTimerEvent * event); - virtual void paintEvent(QPaintEvent * event); + virtual void timerEvent(QTimerEvent * event) Q_DECL_OVERRIDE; + virtual void paintEvent(QPaintEvent * event) Q_DECL_OVERRIDE; private: int m_angle; int m_timerId; diff --git a/src/3rdparty/fancylineedit/fancylineedit.cpp b/src/3rdparty/fancylineedit/fancylineedit.cpp index 84d9fa1b4..e6357064b 100644 --- a/src/3rdparty/fancylineedit/fancylineedit.cpp +++ b/src/3rdparty/fancylineedit/fancylineedit.cpp @@ -99,7 +99,7 @@ class FancyLineEditPrivate : public QObject public: explicit FancyLineEditPrivate(FancyLineEdit *parent); - virtual bool eventFilter(QObject *obj, QEvent *event); + virtual bool eventFilter(QObject *obj, QEvent *event) Q_DECL_OVERRIDE; FancyLineEdit *m_lineEdit; QPixmap m_pixmap[2]; diff --git a/src/3rdparty/fancylineedit/fancylineedit.h b/src/3rdparty/fancylineedit/fancylineedit.h index a148c3df2..a9b995005 100644 --- a/src/3rdparty/fancylineedit/fancylineedit.h +++ b/src/3rdparty/fancylineedit/fancylineedit.h @@ -45,7 +45,7 @@ class IconButton: public QAbstractButton Q_PROPERTY(QPixmap pixmap READ pixmap WRITE setPixmap) public: explicit IconButton(QWidget *parent = 0); - void paintEvent(QPaintEvent *event); + void paintEvent(QPaintEvent *event) Q_DECL_OVERRIDE; void setPixmap(const QPixmap &pixmap) { m_pixmap = pixmap; update(); } QPixmap pixmap() const { return m_pixmap; } float iconOpacity() { return m_iconOpacity; } @@ -105,7 +105,7 @@ private slots: void iconClicked(); protected: - virtual void resizeEvent(QResizeEvent *e); + virtual void resizeEvent(QResizeEvent *e) Q_DECL_OVERRIDE; private: void updateMargins(); diff --git a/src/3rdparty/qtsingleapplication/qtsingleapplication.h b/src/3rdparty/qtsingleapplication/qtsingleapplication.h index 9e8d86cf5..384a71ce8 100644 --- a/src/3rdparty/qtsingleapplication/qtsingleapplication.h +++ b/src/3rdparty/qtsingleapplication/qtsingleapplication.h @@ -50,7 +50,7 @@ public: void setActivationWindow(QWidget* aw, bool activateOnMessage = true); QWidget* activationWindow() const; - bool event(QEvent *event); + bool event(QEvent *event) Q_DECL_OVERRIDE; QString applicationId() const; void setBlock(bool value); diff --git a/src/creds/dummycredentials.h b/src/creds/dummycredentials.h index d6401b2ed..516280fe7 100644 --- a/src/creds/dummycredentials.h +++ b/src/creds/dummycredentials.h @@ -27,17 +27,17 @@ public: QString _user; QString _password; - void syncContextPreInit(CSYNC* ctx); - void syncContextPreStart(CSYNC* ctx); - bool changed(AbstractCredentials* credentials) const; - QString authType() const; - QString user() const; - QNetworkAccessManager* getQNAM() const; - bool ready() const; - bool stillValid(QNetworkReply *reply); - void fetch(Account*); - void persist(Account*); - void invalidateToken(Account *) {} + void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE; + void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE; + bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE; + QString authType() const Q_DECL_OVERRIDE; + QString user() const Q_DECL_OVERRIDE; + QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE; + bool ready() const Q_DECL_OVERRIDE; + bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE; + void fetch(Account*) Q_DECL_OVERRIDE; + void persist(Account*) Q_DECL_OVERRIDE; + void invalidateToken(Account *) Q_DECL_OVERRIDE {} }; } // ns Mirall diff --git a/src/creds/httpcredentials.cpp b/src/creds/httpcredentials.cpp index 72d238713..1312ee33e 100644 --- a/src/creds/httpcredentials.cpp +++ b/src/creds/httpcredentials.cpp @@ -85,7 +85,7 @@ public: HttpCredentialsAccessManager(const HttpCredentials *cred, QObject* parent = 0) : MirallAccessManager(parent), _cred(cred) {} protected: - QNetworkReply *createRequest(Operation op, const QNetworkRequest &request, QIODevice *outgoingData) { + QNetworkReply *createRequest(Operation op, const QNetworkRequest &request, QIODevice *outgoingData) Q_DECL_OVERRIDE { QByteArray credHash = QByteArray(_cred->user().toUtf8()+":"+_cred->password().toUtf8()).toBase64(); QNetworkRequest req(request); req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash); diff --git a/src/creds/httpcredentials.h b/src/creds/httpcredentials.h index 38402fc8c..92360f376 100644 --- a/src/creds/httpcredentials.h +++ b/src/creds/httpcredentials.h @@ -38,19 +38,19 @@ public: HttpCredentials(); HttpCredentials(const QString& user, const QString& password); - void syncContextPreInit(CSYNC* ctx); - void syncContextPreStart(CSYNC* ctx); - bool changed(AbstractCredentials* credentials) const; - QString authType() const; - QNetworkAccessManager* getQNAM() const; - bool ready() const; - void fetch(Account *account); - bool stillValid(QNetworkReply *reply); - void persist(Account *account); - QString user() const; + void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE; + void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE; + bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE; + QString authType() const Q_DECL_OVERRIDE; + QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE; + bool ready() const Q_DECL_OVERRIDE; + void fetch(Account *account) Q_DECL_OVERRIDE; + bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE; + void persist(Account *account) Q_DECL_OVERRIDE; + QString user() const Q_DECL_OVERRIDE; QString password() const; QString queryPassword(bool *ok); - void invalidateToken(Account *account); + void invalidateToken(Account *account) Q_DECL_OVERRIDE; QString fetchUser(Account *account); private Q_SLOTS: diff --git a/src/creds/shibboleth/shibbolethuserjob.h b/src/creds/shibboleth/shibbolethuserjob.h index 8042fe939..3f2c10b59 100644 --- a/src/creds/shibboleth/shibbolethuserjob.h +++ b/src/creds/shibboleth/shibbolethuserjob.h @@ -27,14 +27,14 @@ class ShibbolethUserJob : public AbstractNetworkJob { public: explicit ShibbolethUserJob(Account *account, QObject* parent = 0); public slots: - void start(); + void start() Q_DECL_OVERRIDE; signals: // is always emitted when the job is finished. user is empty in case of error. void userFetched(const QString &user); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; diff --git a/src/creds/shibboleth/shibbolethwebview.h b/src/creds/shibboleth/shibbolethwebview.h index 37b58c8cb..29e642a1f 100644 --- a/src/creds/shibboleth/shibbolethwebview.h +++ b/src/creds/shibboleth/shibbolethwebview.h @@ -37,7 +37,7 @@ public: ShibbolethWebView(Account *account, ShibbolethCookieJar* jar, QWidget* parent = 0); ~ShibbolethWebView(); - void closeEvent(QCloseEvent *event); + void closeEvent(QCloseEvent *event) Q_DECL_OVERRIDE; Q_SIGNALS: void shibbolethCookieReceived(const QNetworkCookie &cookie, Account *account); diff --git a/src/creds/shibbolethcredentials.h b/src/creds/shibbolethcredentials.h index cb778f219..5a58fac4f 100644 --- a/src/creds/shibbolethcredentials.h +++ b/src/creds/shibbolethcredentials.h @@ -43,17 +43,17 @@ public: /* create a credidentials for an already connected account */ ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc); - void syncContextPreInit(CSYNC* ctx); - void syncContextPreStart(CSYNC* ctx); - bool changed(AbstractCredentials* credentials) const; - QString authType() const; - QString user() const; - QNetworkAccessManager* getQNAM() const; - bool ready() const; - void fetch(Account *account); - bool stillValid(QNetworkReply *reply); - void persist(Account *account); - void invalidateToken(Account *account); + void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE; + void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE; + bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE; + QString authType() const Q_DECL_OVERRIDE; + QString user() const Q_DECL_OVERRIDE; + QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE; + bool ready() const Q_DECL_OVERRIDE; + void fetch(Account *account) Q_DECL_OVERRIDE; + bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE; + void persist(Account *account) Q_DECL_OVERRIDE; + void invalidateToken(Account *account) Q_DECL_OVERRIDE; void showLoginWindow(Account*); @@ -62,7 +62,7 @@ public: static QByteArray shibCookieName(); public Q_SLOTS: - void invalidateAndFetch(Account *account); + void invalidateAndFetch(Account *account) Q_DECL_OVERRIDE; void slotHandleAuthentication(QNetworkReply*,QAuthenticator*); private Q_SLOTS: diff --git a/src/mirall/cookiejar.h b/src/mirall/cookiejar.h index 6e84c80f1..acb0c31cf 100644 --- a/src/mirall/cookiejar.h +++ b/src/mirall/cookiejar.h @@ -26,10 +26,10 @@ class OWNCLOUDSYNC_EXPORT CookieJar : public QNetworkCookieJar public: explicit CookieJar(QObject *parent = 0); ~CookieJar(); - bool setCookiesFromUrl(const QList &cookieList, const QUrl &url); - QList cookiesForUrl(const QUrl &url) const; + bool setCookiesFromUrl(const QList &cookieList, const QUrl &url) Q_DECL_OVERRIDE; + QList cookiesForUrl(const QUrl &url) const Q_DECL_OVERRIDE; - virtual bool deleteCookie(const QNetworkCookie & cookie); + virtual bool deleteCookie(const QNetworkCookie & cookie) Q_DECL_OVERRIDE; void clearSessionCookies(); signals: diff --git a/src/mirall/folderstatusmodel.h b/src/mirall/folderstatusmodel.h index 53a5c8594..74acaa08a 100644 --- a/src/mirall/folderstatusmodel.h +++ b/src/mirall/folderstatusmodel.h @@ -24,8 +24,8 @@ class FolderStatusModel : public QStandardItemModel { public: FolderStatusModel(); - virtual Qt::ItemFlags flags( const QModelIndex& ) const; - QVariant data(const QModelIndex &index, int role) const; + virtual Qt::ItemFlags flags( const QModelIndex& ) const Q_DECL_OVERRIDE; + QVariant data(const QModelIndex &index, int role) const Q_DECL_OVERRIDE; }; @@ -52,10 +52,10 @@ class FolderStatusDelegate : public QStyledItemDelegate WarningCount, SyncRunning }; - void paint( QPainter*, const QStyleOptionViewItem&, const QModelIndex& ) const; - QSize sizeHint( const QStyleOptionViewItem&, const QModelIndex& ) const; + void paint( QPainter*, const QStyleOptionViewItem&, const QModelIndex& ) const Q_DECL_OVERRIDE; + QSize sizeHint( const QStyleOptionViewItem&, const QModelIndex& ) const Q_DECL_OVERRIDE; bool editorEvent( QEvent* event, QAbstractItemModel* model, const QStyleOptionViewItem& option, - const QModelIndex& index ); + const QModelIndex& index ) Q_DECL_OVERRIDE; }; } // namespace Mirall diff --git a/src/mirall/folderwizard.h b/src/mirall/folderwizard.h index 95862a029..8db9b1319 100644 --- a/src/mirall/folderwizard.h +++ b/src/mirall/folderwizard.h @@ -43,9 +43,9 @@ public: FolderWizardLocalPath(); ~FolderWizardLocalPath(); - virtual bool isComplete() const; - void initializePage(); - void cleanupPage(); + virtual bool isComplete() const Q_DECL_OVERRIDE; + void initializePage() Q_DECL_OVERRIDE; + void cleanupPage() Q_DECL_OVERRIDE; void setFolderMap( const Folder::Map &fm ) { _folderMap = fm; } protected slots: @@ -68,10 +68,10 @@ public: FolderWizardRemotePath(); ~FolderWizardRemotePath(); - virtual bool isComplete() const; + virtual bool isComplete() const Q_DECL_OVERRIDE; - virtual void initializePage(); - virtual void cleanupPage(); + virtual void initializePage() Q_DECL_OVERRIDE; + virtual void cleanupPage() Q_DECL_OVERRIDE; protected slots: diff --git a/src/mirall/logbrowser.h b/src/mirall/logbrowser.h index b46963ce6..24f2406bb 100644 --- a/src/mirall/logbrowser.h +++ b/src/mirall/logbrowser.h @@ -48,7 +48,7 @@ public: void setLogFile(const QString& , bool ); protected: - void closeEvent(QCloseEvent *); + void closeEvent(QCloseEvent *) Q_DECL_OVERRIDE; protected slots: void slotNewLog( const QString &msg ); diff --git a/src/mirall/mirallaccessmanager.h b/src/mirall/mirallaccessmanager.h index 149dd5ae4..d2fc0e531 100644 --- a/src/mirall/mirallaccessmanager.h +++ b/src/mirall/mirallaccessmanager.h @@ -28,7 +28,7 @@ public: MirallAccessManager(QObject* parent = 0); protected: - QNetworkReply* createRequest(QNetworkAccessManager::Operation op, const QNetworkRequest& request, QIODevice* outgoingData = 0); + QNetworkReply* createRequest(QNetworkAccessManager::Operation op, const QNetworkRequest& request, QIODevice* outgoingData = 0) Q_DECL_OVERRIDE; protected slots: void slotProxyAuthenticationRequired(const QNetworkProxy &proxy, QAuthenticator *authenticator); }; diff --git a/src/mirall/networkjobs.h b/src/mirall/networkjobs.h index 6f0834303..a15ed92b8 100644 --- a/src/mirall/networkjobs.h +++ b/src/mirall/networkjobs.h @@ -114,13 +114,13 @@ class OWNCLOUDSYNC_EXPORT EntityExistsJob : public AbstractNetworkJob { Q_OBJECT public: explicit EntityExistsJob(Account *account, const QString &path, QObject* parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void exists(QNetworkReply*); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; /** @@ -130,13 +130,13 @@ class OWNCLOUDSYNC_EXPORT LsColJob : public AbstractNetworkJob { Q_OBJECT public: explicit LsColJob(Account *account, const QString &path, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void directoryListing(const QStringList &items); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; /** @@ -146,7 +146,7 @@ class PropfindJob : public AbstractNetworkJob { Q_OBJECT public: explicit PropfindJob(Account *account, const QString &path, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; void setProperties(QList properties); QList properties() const; @@ -154,7 +154,7 @@ signals: void result(const QVariantMap &values); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; private: QList _properties; @@ -167,13 +167,13 @@ class OWNCLOUDSYNC_EXPORT MkColJob : public AbstractNetworkJob { Q_OBJECT public: explicit MkColJob(Account *account, const QString &path, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void finished(QNetworkReply::NetworkError); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; /** @@ -183,7 +183,7 @@ class OWNCLOUDSYNC_EXPORT CheckServerJob : public AbstractNetworkJob { Q_OBJECT public: explicit CheckServerJob(Account *account, bool followRedirect = false, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; static QString version(const QVariantMap &info); static QString versionString(const QVariantMap &info); @@ -195,8 +195,8 @@ signals: void timeout(const QUrl&url); private slots: - virtual bool finished(); - virtual void slotTimeout(); + virtual bool finished() Q_DECL_OVERRIDE; + virtual void slotTimeout() Q_DECL_OVERRIDE; private: bool _followRedirects; @@ -212,13 +212,13 @@ class RequestEtagJob : public AbstractNetworkJob { Q_OBJECT public: explicit RequestEtagJob(Account *account, const QString &path, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void etagRetreived(const QString &etag); private slots: - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; /** @@ -228,14 +228,14 @@ class CheckQuotaJob : public AbstractNetworkJob { Q_OBJECT public: explicit CheckQuotaJob(Account *account, const QString &path, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void quotaRetrieved(qint64 totalBytes, qint64 availableBytes); private slots: /** Return true if you want the job to be deleted after this slot has finished running. */ - virtual bool finished(); + virtual bool finished() Q_DECL_OVERRIDE; }; } // namespace Mirall diff --git a/src/mirall/owncloudpropagator.h b/src/mirall/owncloudpropagator.h index d63ec08f3..cfec6653b 100644 --- a/src/mirall/owncloudpropagator.h +++ b/src/mirall/owncloudpropagator.h @@ -102,8 +102,8 @@ public: _subJobs.append(subJob); } - virtual void start(); - virtual void abort() { + virtual void start() Q_DECL_OVERRIDE; + virtual void abort() Q_DECL_OVERRIDE { if (_firstJob) _firstJob->abort(); foreach (PropagatorJob *j, _subJobs) @@ -168,7 +168,7 @@ class PropagateIgnoreJob : public PropagateItemJob { public: PropagateIgnoreJob(OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} - void start() { + void start() Q_DECL_OVERRIDE { SyncFileItem::Status status = _item._status; done(status == SyncFileItem::NoStatus ? SyncFileItem::FileIgnored : status, _item._errorString); } diff --git a/src/mirall/owncloudsetupwizard.h b/src/mirall/owncloudsetupwizard.h index 681b776be..a35c57c2b 100644 --- a/src/mirall/owncloudsetupwizard.h +++ b/src/mirall/owncloudsetupwizard.h @@ -35,22 +35,22 @@ class ValidateDavAuthJob : public AbstractNetworkJob { Q_OBJECT public: ValidateDavAuthJob(Account* account, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void authResult(QNetworkReply*); private slots: - bool finished(); + bool finished() Q_DECL_OVERRIDE; }; class DetermineAuthTypeJob : public AbstractNetworkJob { Q_OBJECT public: explicit DetermineAuthTypeJob(Account *account, QObject *parent = 0); - void start(); + void start() Q_DECL_OVERRIDE; signals: void authType(WizardCommon::AuthType); private slots: - bool finished(); + bool finished() Q_DECL_OVERRIDE; private: int _redirects; }; diff --git a/src/mirall/owncloudtheme.h b/src/mirall/owncloudtheme.h index df6736166..33b33e2a9 100644 --- a/src/mirall/owncloudtheme.h +++ b/src/mirall/owncloudtheme.h @@ -25,21 +25,21 @@ class ownCloudTheme : public Theme public: ownCloudTheme(); - QString configFileName() const; - QString about() const; + QString configFileName() const Q_DECL_OVERRIDE; + QString about() const Q_DECL_OVERRIDE; QPixmap splashScreen() const; QIcon folderIcon( const QString& ) const; - QIcon trayFolderIcon( const QString& ) const; - QIcon folderDisabledIcon() const; - QIcon applicationIcon() const; + QIcon trayFolderIcon( const QString& ) const Q_DECL_OVERRIDE; + QIcon folderDisabledIcon() const Q_DECL_OVERRIDE; + QIcon applicationIcon() const Q_DECL_OVERRIDE; - QVariant customMedia(CustomMediaType type); - QString helpUrl() const; + QVariant customMedia(CustomMediaType type) Q_DECL_OVERRIDE; + QString helpUrl() const Q_DECL_OVERRIDE; - QColor wizardHeaderBackgroundColor() const; - QColor wizardHeaderTitleColor() const; - QPixmap wizardHeaderLogo() const; + QColor wizardHeaderBackgroundColor() const Q_DECL_OVERRIDE; + QColor wizardHeaderTitleColor() const Q_DECL_OVERRIDE; + QPixmap wizardHeaderLogo() const Q_DECL_OVERRIDE; private: diff --git a/src/mirall/propagator_legacy.h b/src/mirall/propagator_legacy.h index a624064b7..eee25c0dd 100644 --- a/src/mirall/propagator_legacy.h +++ b/src/mirall/propagator_legacy.h @@ -25,7 +25,7 @@ public: explicit PropagateUploadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) , _chunked_done(0), _chunked_total_size(0), _previousFileSize(0) {} - void start(); + void start() Q_DECL_OVERRIDE; private: // Log callback for httpbf static void _log_callback(const char *func, const char *text, void*) @@ -54,7 +54,7 @@ class PropagateDownloadFileLegacy: public PropagateNeonJob { public: explicit PropagateDownloadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item), _file(0) {} - void start(); + void start() Q_DECL_OVERRIDE; private: QFile *_file; QScopedPointer _decompress; diff --git a/src/mirall/propagator_qnam.cpp b/src/mirall/propagator_qnam.cpp index df2c22985..475a5b98a 100644 --- a/src/mirall/propagator_qnam.cpp +++ b/src/mirall/propagator_qnam.cpp @@ -129,12 +129,12 @@ public: _file->seek(start); } - virtual qint64 writeData(const char* , qint64 ) { + virtual qint64 writeData(const char* , qint64 ) Q_DECL_OVERRIDE { Q_ASSERT(!"write to read only device"); return 0; } - virtual qint64 readData(char* data, qint64 maxlen) { + virtual qint64 readData(char* data, qint64 maxlen) Q_DECL_OVERRIDE { maxlen = qMin(maxlen, chunkSize() - _read); if (maxlen == 0) return 0; @@ -145,25 +145,25 @@ public: return ret; } - virtual bool atEnd() const { + virtual bool atEnd() const Q_DECL_OVERRIDE { return _read >= chunkSize() || _file->atEnd(); } - virtual qint64 size() const{ + virtual qint64 size() const Q_DECL_OVERRIDE{ return _size; } - qint64 bytesAvailable() const + qint64 bytesAvailable() const Q_DECL_OVERRIDE { return _size - _read + QIODevice::bytesAvailable(); } // random access, we can seek - virtual bool isSequential() const{ + virtual bool isSequential() const Q_DECL_OVERRIDE{ return false; } - virtual bool seek ( qint64 pos ) { + virtual bool seek ( qint64 pos ) Q_DECL_OVERRIDE { _read = pos; return _file->seek(pos + _start); } diff --git a/src/mirall/propagator_qnam.h b/src/mirall/propagator_qnam.h index f8c727b31..fee64cf5a 100644 --- a/src/mirall/propagator_qnam.h +++ b/src/mirall/propagator_qnam.h @@ -61,9 +61,9 @@ public: const QMap &headers, QObject* parent = 0) : AbstractNetworkJob(account, path, parent), _device(device), _headers(headers) {} - virtual void start(); + virtual void start() Q_DECL_OVERRIDE; - virtual bool finished() { + virtual bool finished() Q_DECL_OVERRIDE { emit finishedSignal(); return true; } @@ -72,7 +72,7 @@ public: return _errorString.isEmpty() ? reply()->errorString() : _errorString; }; - virtual void slotTimeout(); + virtual void slotTimeout() Q_DECL_OVERRIDE; signals: @@ -93,11 +93,11 @@ class PropagateUploadFileQNAM : public PropagateItemJob { public: PropagateUploadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item), _startChunk(0), _currentChunk(0), _chunkCount(0), _transferId(0) {} - void start(); + void start() Q_DECL_OVERRIDE; private slots: void slotPutFinished(); void slotUploadProgress(qint64,qint64); - void abort(); + void abort() Q_DECL_OVERRIDE; void startNextChunk(); void finalize(const Mirall::SyncFileItem&); }; @@ -123,8 +123,8 @@ public: const QMap &headers, QObject* parent = 0); - virtual void start(); - virtual bool finished() { + virtual void start() Q_DECL_OVERRIDE; + virtual bool finished() Q_DECL_OVERRIDE { emit finishedSignal(); return true; } @@ -135,7 +135,7 @@ public: SyncFileItem::Status errorStatus() { return _errorStatus; } - virtual void slotTimeout(); + virtual void slotTimeout() Q_DECL_OVERRIDE; QByteArray &etag() { return _etag; } @@ -159,10 +159,10 @@ class PropagateDownloadFileQNAM : public PropagateItemJob { public: PropagateDownloadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item), _startSize(0) {} - void start(); + void start() Q_DECL_OVERRIDE; private slots: void slotGetFinished(); - void abort(); + void abort() Q_DECL_OVERRIDE; void downloadFinished(); void slotDownloadProgress(qint64,qint64); diff --git a/src/mirall/propagatorjobs.h b/src/mirall/propagatorjobs.h index 3fc512acf..df7a5e472 100644 --- a/src/mirall/propagatorjobs.h +++ b/src/mirall/propagatorjobs.h @@ -74,26 +74,26 @@ class PropagateLocalRemove : public PropagateItemJob { Q_OBJECT public: PropagateLocalRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; class PropagateLocalMkdir : public PropagateItemJob { Q_OBJECT public: PropagateLocalMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; class PropagateRemoteRemove : public PropagateNeonJob { Q_OBJECT public: PropagateRemoteRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; class PropagateRemoteMkdir : public PropagateNeonJob { Q_OBJECT public: PropagateRemoteMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; private: static void propfind_results(void *userdata, const ne_uri *uri, const ne_prop_result_set *set); friend class PropagateDirectory; // So it can access the _item; @@ -102,13 +102,13 @@ class PropagateLocalRename : public PropagateItemJob { Q_OBJECT public: PropagateLocalRename (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; class PropagateRemoteRename : public PropagateNeonJob { Q_OBJECT public: PropagateRemoteRename (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; @@ -117,7 +117,7 @@ class UpdateMTimeAndETagJob : public PropagateNeonJob{ Q_OBJECT public: UpdateMTimeAndETagJob (OwncloudPropagator* propagator, const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} - void start(); + void start() Q_DECL_OVERRIDE; }; diff --git a/src/mirall/settingsdialog.h b/src/mirall/settingsdialog.h index 373f5efc6..fe82e77e5 100644 --- a/src/mirall/settingsdialog.h +++ b/src/mirall/settingsdialog.h @@ -49,8 +49,8 @@ public slots: void showActivityPage(); protected: - void reject(); - void accept(); + void reject() Q_DECL_OVERRIDE; + void accept() Q_DECL_OVERRIDE; private: Ui::SettingsDialog *_ui; diff --git a/src/mirall/sslerrordialog.h b/src/mirall/sslerrordialog.h index ad53e4a9f..b8639844a 100644 --- a/src/mirall/sslerrordialog.h +++ b/src/mirall/sslerrordialog.h @@ -33,7 +33,7 @@ class SslErrorDialog; class SslDialogErrorHandler : public AbstractSslErrorHandler { public: - bool handleErrors(QList errors, QList *certs, Account*); + bool handleErrors(QList errors, QList *certs, Account*) Q_DECL_OVERRIDE; }; class SslErrorDialog : public QDialog diff --git a/src/owncloudcmd/simplesslerrorhandler.h b/src/owncloudcmd/simplesslerrorhandler.h index 0a6bfd702..8e6876161 100644 --- a/src/owncloudcmd/simplesslerrorhandler.h +++ b/src/owncloudcmd/simplesslerrorhandler.h @@ -20,7 +20,7 @@ class QSslCertificate; class SimpleSslErrorHandler : public Mirall::AbstractSslErrorHandler { public: - bool handleErrors(QList errors, QList *certs, Mirall::Account*); + bool handleErrors(QList errors, QList *certs, Mirall::Account*) Q_DECL_OVERRIDE; }; #endif // SIMPLESSLERRORHANDLER_H diff --git a/src/updater/ocupdater.h b/src/updater/ocupdater.h index 2b7c9765b..1041517bc 100644 --- a/src/updater/ocupdater.h +++ b/src/updater/ocupdater.h @@ -40,8 +40,8 @@ public: bool performUpdate(); - void checkForUpdate(); - void backgroundCheckForUpdate(); + void checkForUpdate() Q_DECL_OVERRIDE; + void backgroundCheckForUpdate() Q_DECL_OVERRIDE; QString statusString() const; int downloadState() const; @@ -77,7 +77,7 @@ class NSISUpdater : public OCUpdater { public: enum UpdateState { NoUpdate = 0, UpdateAvailable, UpdateFailed }; explicit NSISUpdater(const QUrl &url, QObject *parent = 0); - bool handleStartup(); + bool handleStartup() Q_DECL_OVERRIDE; private slots: void slotSetSeenVersion(); void slotDownloadFinished(); @@ -85,7 +85,7 @@ private slots: private: NSISUpdater::UpdateState updateStateOnStart(); void showDialog(const UpdateInfo &info); - void versionInfoArrived(const UpdateInfo &info); + void versionInfoArrived(const UpdateInfo &info) Q_DECL_OVERRIDE; QScopedPointer _file; QString _targetFile; bool _showFallbackMessage; @@ -98,10 +98,10 @@ class PassiveUpdateNotifier : public OCUpdater { Q_OBJECT public: explicit PassiveUpdateNotifier(const QUrl &url, QObject *parent = 0); - bool handleStartup() { return false; } + bool handleStartup() Q_DECL_OVERRIDE { return false; } private: - void versionInfoArrived(const UpdateInfo &info); + void versionInfoArrived(const UpdateInfo &info) Q_DECL_OVERRIDE; }; diff --git a/src/updater/sparkleupdater.h b/src/updater/sparkleupdater.h index 424f11fa5..373e8a25c 100644 --- a/src/updater/sparkleupdater.h +++ b/src/updater/sparkleupdater.h @@ -26,9 +26,9 @@ public: ~SparkleUpdater(); // unused in this updater - void checkForUpdate(); - void backgroundCheckForUpdate(); - bool handleStartup() { return false; } + void checkForUpdate() Q_DECL_OVERRIDE; + void backgroundCheckForUpdate() Q_DECL_OVERRIDE; + bool handleStartup() Q_DECL_OVERRIDE { return false; } private: class Private; Private *d; diff --git a/src/wizard/abstractcredswizardpage.h b/src/wizard/abstractcredswizardpage.h index f79fae414..a2ef1fe9a 100644 --- a/src/wizard/abstractcredswizardpage.h +++ b/src/wizard/abstractcredswizardpage.h @@ -24,7 +24,7 @@ class AbstractCredentials; class AbstractCredentialsWizardPage : public QWizardPage { public: - void cleanupPage(); + void cleanupPage() Q_DECL_OVERRIDE; virtual AbstractCredentials* getCredentials() const = 0; }; diff --git a/src/wizard/owncloudadvancedsetuppage.h b/src/wizard/owncloudadvancedsetuppage.h index 5d01e21d2..1d897fe77 100644 --- a/src/wizard/owncloudadvancedsetuppage.h +++ b/src/wizard/owncloudadvancedsetuppage.h @@ -31,10 +31,10 @@ class OwncloudAdvancedSetupPage: public QWizardPage public: OwncloudAdvancedSetupPage(); - virtual bool isComplete() const; - virtual void initializePage(); - virtual int nextId() const; - bool validatePage(); + virtual bool isComplete() const Q_DECL_OVERRIDE; + virtual void initializePage() Q_DECL_OVERRIDE; + virtual int nextId() const Q_DECL_OVERRIDE; + bool validatePage() Q_DECL_OVERRIDE; QString localFolder() const; void setRemoteFolder( const QString& remoteFolder); void setMultipleFoldersExist( bool exist ); diff --git a/src/wizard/owncloudhttpcredspage.h b/src/wizard/owncloudhttpcredspage.h index 86e4cf2c3..70356836c 100644 --- a/src/wizard/owncloudhttpcredspage.h +++ b/src/wizard/owncloudhttpcredspage.h @@ -30,12 +30,12 @@ class OwncloudHttpCredsPage : public AbstractCredentialsWizardPage public: OwncloudHttpCredsPage(); - AbstractCredentials* getCredentials() const; + AbstractCredentials* getCredentials() const Q_DECL_OVERRIDE; - void initializePage(); - void cleanupPage(); - bool validatePage(); - int nextId() const; + void initializePage() Q_DECL_OVERRIDE; + void cleanupPage() Q_DECL_OVERRIDE; + bool validatePage() Q_DECL_OVERRIDE; + int nextId() const Q_DECL_OVERRIDE; void setConnected(bool connected); void setErrorString( const QString& err ); void setConfigExists(bool config); diff --git a/src/wizard/owncloudsetuppage.h b/src/wizard/owncloudsetuppage.h index 7161a3665..0d30e6a93 100644 --- a/src/wizard/owncloudsetuppage.h +++ b/src/wizard/owncloudsetuppage.h @@ -33,12 +33,12 @@ class OwncloudSetupPage: public QWizardPage public: OwncloudSetupPage(); - virtual bool isComplete() const; - virtual void initializePage(); - virtual int nextId() const; + virtual bool isComplete() const Q_DECL_OVERRIDE; + virtual void initializePage() Q_DECL_OVERRIDE; + virtual int nextId() const Q_DECL_OVERRIDE; void setServerUrl( const QString& ); void setAllowPasswordStorage( bool ); - bool validatePage(); + bool validatePage() Q_DECL_OVERRIDE; QString url() const; QString localFolder() const; void setRemoteFolder( const QString& remoteFolder); diff --git a/src/wizard/owncloudshibbolethcredspage.h b/src/wizard/owncloudshibbolethcredspage.h index 28f635363..14296431d 100644 --- a/src/wizard/owncloudshibbolethcredspage.h +++ b/src/wizard/owncloudshibbolethcredspage.h @@ -33,17 +33,17 @@ class OwncloudShibbolethCredsPage : public AbstractCredentialsWizardPage public: OwncloudShibbolethCredsPage(); - AbstractCredentials* getCredentials() const; + AbstractCredentials* getCredentials() const Q_DECL_OVERRIDE; - void initializePage(); - int nextId() const; + void initializePage() Q_DECL_OVERRIDE; + int nextId() const Q_DECL_OVERRIDE; void setConnected(); Q_SIGNALS: void connectToOCUrl(const QString&); public Q_SLOTS: - void setVisible(bool visible); + void setVisible(bool visible) Q_DECL_OVERRIDE; private Q_SLOTS: void slotShibbolethCookieReceived(const QNetworkCookie&, Account*); diff --git a/src/wizard/owncloudwizardresultpage.h b/src/wizard/owncloudwizardresultpage.h index bd7061325..0390087be 100644 --- a/src/wizard/owncloudwizardresultpage.h +++ b/src/wizard/owncloudwizardresultpage.h @@ -29,8 +29,8 @@ public: OwncloudWizardResultPage(); ~OwncloudWizardResultPage(); - bool isComplete() const; - void initializePage(); + bool isComplete() const Q_DECL_OVERRIDE; + void initializePage() Q_DECL_OVERRIDE; void setRemoteFolder( const QString& remoteFolder); public slots: