Add Q_DECL_OVERRIDE for all function that are overriding something

This was made automatically with
clang-modernize -override-macros -add-override
This commit is contained in:
Olivier Goffart 2014-07-09 23:22:28 +02:00
parent e0c2e8ed86
commit bcfa34357b
34 changed files with 153 additions and 153 deletions

View file

@ -64,8 +64,8 @@ public:
*/ */
const QColor & color() const { return m_color; } const QColor & color() const { return m_color; }
virtual QSize sizeHint() const; virtual QSize sizeHint() const Q_DECL_OVERRIDE;
int heightForWidth(int w) const; int heightForWidth(int w) const Q_DECL_OVERRIDE;
public slots: public slots:
/*! Starts the spin animation. /*! Starts the spin animation.
\sa stopAnimation isAnimated \sa stopAnimation isAnimated
@ -95,8 +95,8 @@ public slots:
*/ */
void setColor(const QColor & color); void setColor(const QColor & color);
protected: protected:
virtual void timerEvent(QTimerEvent * event); virtual void timerEvent(QTimerEvent * event) Q_DECL_OVERRIDE;
virtual void paintEvent(QPaintEvent * event); virtual void paintEvent(QPaintEvent * event) Q_DECL_OVERRIDE;
private: private:
int m_angle; int m_angle;
int m_timerId; int m_timerId;

View file

@ -99,7 +99,7 @@ class FancyLineEditPrivate : public QObject
public: public:
explicit FancyLineEditPrivate(FancyLineEdit *parent); explicit FancyLineEditPrivate(FancyLineEdit *parent);
virtual bool eventFilter(QObject *obj, QEvent *event); virtual bool eventFilter(QObject *obj, QEvent *event) Q_DECL_OVERRIDE;
FancyLineEdit *m_lineEdit; FancyLineEdit *m_lineEdit;
QPixmap m_pixmap[2]; QPixmap m_pixmap[2];

View file

@ -45,7 +45,7 @@ class IconButton: public QAbstractButton
Q_PROPERTY(QPixmap pixmap READ pixmap WRITE setPixmap) Q_PROPERTY(QPixmap pixmap READ pixmap WRITE setPixmap)
public: public:
explicit IconButton(QWidget *parent = 0); 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(); } void setPixmap(const QPixmap &pixmap) { m_pixmap = pixmap; update(); }
QPixmap pixmap() const { return m_pixmap; } QPixmap pixmap() const { return m_pixmap; }
float iconOpacity() { return m_iconOpacity; } float iconOpacity() { return m_iconOpacity; }
@ -105,7 +105,7 @@ private slots:
void iconClicked(); void iconClicked();
protected: protected:
virtual void resizeEvent(QResizeEvent *e); virtual void resizeEvent(QResizeEvent *e) Q_DECL_OVERRIDE;
private: private:
void updateMargins(); void updateMargins();

View file

@ -50,7 +50,7 @@ public:
void setActivationWindow(QWidget* aw, bool activateOnMessage = true); void setActivationWindow(QWidget* aw, bool activateOnMessage = true);
QWidget* activationWindow() const; QWidget* activationWindow() const;
bool event(QEvent *event); bool event(QEvent *event) Q_DECL_OVERRIDE;
QString applicationId() const; QString applicationId() const;
void setBlock(bool value); void setBlock(bool value);

View file

@ -27,17 +27,17 @@ public:
QString _user; QString _user;
QString _password; QString _password;
void syncContextPreInit(CSYNC* ctx); void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
void syncContextPreStart(CSYNC* ctx); void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
bool changed(AbstractCredentials* credentials) const; bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
QString authType() const; QString authType() const Q_DECL_OVERRIDE;
QString user() const; QString user() const Q_DECL_OVERRIDE;
QNetworkAccessManager* getQNAM() const; QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
bool ready() const; bool ready() const Q_DECL_OVERRIDE;
bool stillValid(QNetworkReply *reply); bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
void fetch(Account*); void fetch(Account*) Q_DECL_OVERRIDE;
void persist(Account*); void persist(Account*) Q_DECL_OVERRIDE;
void invalidateToken(Account *) {} void invalidateToken(Account *) Q_DECL_OVERRIDE {}
}; };
} // ns Mirall } // ns Mirall

View file

@ -85,7 +85,7 @@ public:
HttpCredentialsAccessManager(const HttpCredentials *cred, QObject* parent = 0) HttpCredentialsAccessManager(const HttpCredentials *cred, QObject* parent = 0)
: MirallAccessManager(parent), _cred(cred) {} : MirallAccessManager(parent), _cred(cred) {}
protected: 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(); QByteArray credHash = QByteArray(_cred->user().toUtf8()+":"+_cred->password().toUtf8()).toBase64();
QNetworkRequest req(request); QNetworkRequest req(request);
req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash); req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash);

View file

@ -38,19 +38,19 @@ public:
HttpCredentials(); HttpCredentials();
HttpCredentials(const QString& user, const QString& password); HttpCredentials(const QString& user, const QString& password);
void syncContextPreInit(CSYNC* ctx); void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
void syncContextPreStart(CSYNC* ctx); void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
bool changed(AbstractCredentials* credentials) const; bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
QString authType() const; QString authType() const Q_DECL_OVERRIDE;
QNetworkAccessManager* getQNAM() const; QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
bool ready() const; bool ready() const Q_DECL_OVERRIDE;
void fetch(Account *account); void fetch(Account *account) Q_DECL_OVERRIDE;
bool stillValid(QNetworkReply *reply); bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
void persist(Account *account); void persist(Account *account) Q_DECL_OVERRIDE;
QString user() const; QString user() const Q_DECL_OVERRIDE;
QString password() const; QString password() const;
QString queryPassword(bool *ok); QString queryPassword(bool *ok);
void invalidateToken(Account *account); void invalidateToken(Account *account) Q_DECL_OVERRIDE;
QString fetchUser(Account *account); QString fetchUser(Account *account);
private Q_SLOTS: private Q_SLOTS:

View file

@ -27,14 +27,14 @@ class ShibbolethUserJob : public AbstractNetworkJob {
public: public:
explicit ShibbolethUserJob(Account *account, QObject* parent = 0); explicit ShibbolethUserJob(Account *account, QObject* parent = 0);
public slots: public slots:
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
// is always emitted when the job is finished. user is empty in case of error. // is always emitted when the job is finished. user is empty in case of error.
void userFetched(const QString &user); void userFetched(const QString &user);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
}; };

View file

@ -37,7 +37,7 @@ public:
ShibbolethWebView(Account *account, ShibbolethCookieJar* jar, QWidget* parent = 0); ShibbolethWebView(Account *account, ShibbolethCookieJar* jar, QWidget* parent = 0);
~ShibbolethWebView(); ~ShibbolethWebView();
void closeEvent(QCloseEvent *event); void closeEvent(QCloseEvent *event) Q_DECL_OVERRIDE;
Q_SIGNALS: Q_SIGNALS:
void shibbolethCookieReceived(const QNetworkCookie &cookie, Account *account); void shibbolethCookieReceived(const QNetworkCookie &cookie, Account *account);

View file

@ -43,17 +43,17 @@ public:
/* create a credidentials for an already connected account */ /* create a credidentials for an already connected account */
ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc); ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc);
void syncContextPreInit(CSYNC* ctx); void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
void syncContextPreStart(CSYNC* ctx); void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
bool changed(AbstractCredentials* credentials) const; bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
QString authType() const; QString authType() const Q_DECL_OVERRIDE;
QString user() const; QString user() const Q_DECL_OVERRIDE;
QNetworkAccessManager* getQNAM() const; QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
bool ready() const; bool ready() const Q_DECL_OVERRIDE;
void fetch(Account *account); void fetch(Account *account) Q_DECL_OVERRIDE;
bool stillValid(QNetworkReply *reply); bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
void persist(Account *account); void persist(Account *account) Q_DECL_OVERRIDE;
void invalidateToken(Account *account); void invalidateToken(Account *account) Q_DECL_OVERRIDE;
void showLoginWindow(Account*); void showLoginWindow(Account*);
@ -62,7 +62,7 @@ public:
static QByteArray shibCookieName(); static QByteArray shibCookieName();
public Q_SLOTS: public Q_SLOTS:
void invalidateAndFetch(Account *account); void invalidateAndFetch(Account *account) Q_DECL_OVERRIDE;
void slotHandleAuthentication(QNetworkReply*,QAuthenticator*); void slotHandleAuthentication(QNetworkReply*,QAuthenticator*);
private Q_SLOTS: private Q_SLOTS:

View file

@ -26,10 +26,10 @@ class OWNCLOUDSYNC_EXPORT CookieJar : public QNetworkCookieJar
public: public:
explicit CookieJar(QObject *parent = 0); explicit CookieJar(QObject *parent = 0);
~CookieJar(); ~CookieJar();
bool setCookiesFromUrl(const QList<QNetworkCookie> &cookieList, const QUrl &url); bool setCookiesFromUrl(const QList<QNetworkCookie> &cookieList, const QUrl &url) Q_DECL_OVERRIDE;
QList<QNetworkCookie> cookiesForUrl(const QUrl &url) const; QList<QNetworkCookie> 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(); void clearSessionCookies();
signals: signals:

View file

@ -24,8 +24,8 @@ class FolderStatusModel : public QStandardItemModel
{ {
public: public:
FolderStatusModel(); FolderStatusModel();
virtual Qt::ItemFlags flags( const QModelIndex& ) const; virtual Qt::ItemFlags flags( const QModelIndex& ) const Q_DECL_OVERRIDE;
QVariant data(const QModelIndex &index, int role) const; QVariant data(const QModelIndex &index, int role) const Q_DECL_OVERRIDE;
}; };
@ -52,10 +52,10 @@ class FolderStatusDelegate : public QStyledItemDelegate
WarningCount, WarningCount,
SyncRunning SyncRunning
}; };
void paint( QPainter*, const QStyleOptionViewItem&, const QModelIndex& ) const; void paint( QPainter*, const QStyleOptionViewItem&, const QModelIndex& ) const Q_DECL_OVERRIDE;
QSize sizeHint( const QStyleOptionViewItem&, const QModelIndex& ) const; QSize sizeHint( const QStyleOptionViewItem&, const QModelIndex& ) const Q_DECL_OVERRIDE;
bool editorEvent( QEvent* event, QAbstractItemModel* model, const QStyleOptionViewItem& option, bool editorEvent( QEvent* event, QAbstractItemModel* model, const QStyleOptionViewItem& option,
const QModelIndex& index ); const QModelIndex& index ) Q_DECL_OVERRIDE;
}; };
} // namespace Mirall } // namespace Mirall

View file

@ -43,9 +43,9 @@ public:
FolderWizardLocalPath(); FolderWizardLocalPath();
~FolderWizardLocalPath(); ~FolderWizardLocalPath();
virtual bool isComplete() const; virtual bool isComplete() const Q_DECL_OVERRIDE;
void initializePage(); void initializePage() Q_DECL_OVERRIDE;
void cleanupPage(); void cleanupPage() Q_DECL_OVERRIDE;
void setFolderMap( const Folder::Map &fm ) { _folderMap = fm; } void setFolderMap( const Folder::Map &fm ) { _folderMap = fm; }
protected slots: protected slots:
@ -68,10 +68,10 @@ public:
FolderWizardRemotePath(); FolderWizardRemotePath();
~FolderWizardRemotePath(); ~FolderWizardRemotePath();
virtual bool isComplete() const; virtual bool isComplete() const Q_DECL_OVERRIDE;
virtual void initializePage(); virtual void initializePage() Q_DECL_OVERRIDE;
virtual void cleanupPage(); virtual void cleanupPage() Q_DECL_OVERRIDE;
protected slots: protected slots:

View file

@ -48,7 +48,7 @@ public:
void setLogFile(const QString& , bool ); void setLogFile(const QString& , bool );
protected: protected:
void closeEvent(QCloseEvent *); void closeEvent(QCloseEvent *) Q_DECL_OVERRIDE;
protected slots: protected slots:
void slotNewLog( const QString &msg ); void slotNewLog( const QString &msg );

View file

@ -28,7 +28,7 @@ public:
MirallAccessManager(QObject* parent = 0); MirallAccessManager(QObject* parent = 0);
protected: 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: protected slots:
void slotProxyAuthenticationRequired(const QNetworkProxy &proxy, QAuthenticator *authenticator); void slotProxyAuthenticationRequired(const QNetworkProxy &proxy, QAuthenticator *authenticator);
}; };

View file

@ -114,13 +114,13 @@ class OWNCLOUDSYNC_EXPORT EntityExistsJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit EntityExistsJob(Account *account, const QString &path, QObject* parent = 0); explicit EntityExistsJob(Account *account, const QString &path, QObject* parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void exists(QNetworkReply*); void exists(QNetworkReply*);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
}; };
/** /**
@ -130,13 +130,13 @@ class OWNCLOUDSYNC_EXPORT LsColJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit LsColJob(Account *account, const QString &path, QObject *parent = 0); explicit LsColJob(Account *account, const QString &path, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void directoryListing(const QStringList &items); void directoryListing(const QStringList &items);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
}; };
/** /**
@ -146,7 +146,7 @@ class PropfindJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit PropfindJob(Account *account, const QString &path, QObject *parent = 0); explicit PropfindJob(Account *account, const QString &path, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
void setProperties(QList<QByteArray> properties); void setProperties(QList<QByteArray> properties);
QList<QByteArray> properties() const; QList<QByteArray> properties() const;
@ -154,7 +154,7 @@ signals:
void result(const QVariantMap &values); void result(const QVariantMap &values);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
private: private:
QList<QByteArray> _properties; QList<QByteArray> _properties;
@ -167,13 +167,13 @@ class OWNCLOUDSYNC_EXPORT MkColJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit MkColJob(Account *account, const QString &path, QObject *parent = 0); explicit MkColJob(Account *account, const QString &path, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void finished(QNetworkReply::NetworkError); void finished(QNetworkReply::NetworkError);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
}; };
/** /**
@ -183,7 +183,7 @@ class OWNCLOUDSYNC_EXPORT CheckServerJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit CheckServerJob(Account *account, bool followRedirect = false, QObject *parent = 0); 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 version(const QVariantMap &info);
static QString versionString(const QVariantMap &info); static QString versionString(const QVariantMap &info);
@ -195,8 +195,8 @@ signals:
void timeout(const QUrl&url); void timeout(const QUrl&url);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
virtual void slotTimeout(); virtual void slotTimeout() Q_DECL_OVERRIDE;
private: private:
bool _followRedirects; bool _followRedirects;
@ -212,13 +212,13 @@ class RequestEtagJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit RequestEtagJob(Account *account, const QString &path, QObject *parent = 0); explicit RequestEtagJob(Account *account, const QString &path, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void etagRetreived(const QString &etag); void etagRetreived(const QString &etag);
private slots: private slots:
virtual bool finished(); virtual bool finished() Q_DECL_OVERRIDE;
}; };
/** /**
@ -228,14 +228,14 @@ class CheckQuotaJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit CheckQuotaJob(Account *account, const QString &path, QObject *parent = 0); explicit CheckQuotaJob(Account *account, const QString &path, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void quotaRetrieved(qint64 totalBytes, qint64 availableBytes); void quotaRetrieved(qint64 totalBytes, qint64 availableBytes);
private slots: private slots:
/** Return true if you want the job to be deleted after this slot has finished running. */ /** 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 } // namespace Mirall

View file

@ -102,8 +102,8 @@ public:
_subJobs.append(subJob); _subJobs.append(subJob);
} }
virtual void start(); virtual void start() Q_DECL_OVERRIDE;
virtual void abort() { virtual void abort() Q_DECL_OVERRIDE {
if (_firstJob) if (_firstJob)
_firstJob->abort(); _firstJob->abort();
foreach (PropagatorJob *j, _subJobs) foreach (PropagatorJob *j, _subJobs)
@ -168,7 +168,7 @@ class PropagateIgnoreJob : public PropagateItemJob {
public: public:
PropagateIgnoreJob(OwncloudPropagator* propagator,const SyncFileItem& item) PropagateIgnoreJob(OwncloudPropagator* propagator,const SyncFileItem& item)
: PropagateItemJob(propagator, item) {} : PropagateItemJob(propagator, item) {}
void start() { void start() Q_DECL_OVERRIDE {
SyncFileItem::Status status = _item._status; SyncFileItem::Status status = _item._status;
done(status == SyncFileItem::NoStatus ? SyncFileItem::FileIgnored : status, _item._errorString); done(status == SyncFileItem::NoStatus ? SyncFileItem::FileIgnored : status, _item._errorString);
} }

View file

@ -35,22 +35,22 @@ class ValidateDavAuthJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
ValidateDavAuthJob(Account* account, QObject *parent = 0); ValidateDavAuthJob(Account* account, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void authResult(QNetworkReply*); void authResult(QNetworkReply*);
private slots: private slots:
bool finished(); bool finished() Q_DECL_OVERRIDE;
}; };
class DetermineAuthTypeJob : public AbstractNetworkJob { class DetermineAuthTypeJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
explicit DetermineAuthTypeJob(Account *account, QObject *parent = 0); explicit DetermineAuthTypeJob(Account *account, QObject *parent = 0);
void start(); void start() Q_DECL_OVERRIDE;
signals: signals:
void authType(WizardCommon::AuthType); void authType(WizardCommon::AuthType);
private slots: private slots:
bool finished(); bool finished() Q_DECL_OVERRIDE;
private: private:
int _redirects; int _redirects;
}; };

View file

@ -25,21 +25,21 @@ class ownCloudTheme : public Theme
public: public:
ownCloudTheme(); ownCloudTheme();
QString configFileName() const; QString configFileName() const Q_DECL_OVERRIDE;
QString about() const; QString about() const Q_DECL_OVERRIDE;
QPixmap splashScreen() const; QPixmap splashScreen() const;
QIcon folderIcon( const QString& ) const; QIcon folderIcon( const QString& ) const;
QIcon trayFolderIcon( const QString& ) const; QIcon trayFolderIcon( const QString& ) const Q_DECL_OVERRIDE;
QIcon folderDisabledIcon() const; QIcon folderDisabledIcon() const Q_DECL_OVERRIDE;
QIcon applicationIcon() const; QIcon applicationIcon() const Q_DECL_OVERRIDE;
QVariant customMedia(CustomMediaType type); QVariant customMedia(CustomMediaType type) Q_DECL_OVERRIDE;
QString helpUrl() const; QString helpUrl() const Q_DECL_OVERRIDE;
QColor wizardHeaderBackgroundColor() const; QColor wizardHeaderBackgroundColor() const Q_DECL_OVERRIDE;
QColor wizardHeaderTitleColor() const; QColor wizardHeaderTitleColor() const Q_DECL_OVERRIDE;
QPixmap wizardHeaderLogo() const; QPixmap wizardHeaderLogo() const Q_DECL_OVERRIDE;
private: private:

View file

@ -25,7 +25,7 @@ public:
explicit PropagateUploadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item) explicit PropagateUploadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item)
: PropagateNeonJob(propagator, item) : PropagateNeonJob(propagator, item)
, _chunked_done(0), _chunked_total_size(0), _previousFileSize(0) {} , _chunked_done(0), _chunked_total_size(0), _previousFileSize(0) {}
void start(); void start() Q_DECL_OVERRIDE;
private: private:
// Log callback for httpbf // Log callback for httpbf
static void _log_callback(const char *func, const char *text, void*) static void _log_callback(const char *func, const char *text, void*)
@ -54,7 +54,7 @@ class PropagateDownloadFileLegacy: public PropagateNeonJob {
public: public:
explicit PropagateDownloadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item) explicit PropagateDownloadFileLegacy(OwncloudPropagator* propagator,const SyncFileItem& item)
: PropagateNeonJob(propagator, item), _file(0) {} : PropagateNeonJob(propagator, item), _file(0) {}
void start(); void start() Q_DECL_OVERRIDE;
private: private:
QFile *_file; QFile *_file;
QScopedPointer<ne_decompress, ScopedPointerHelpers> _decompress; QScopedPointer<ne_decompress, ScopedPointerHelpers> _decompress;

View file

@ -129,12 +129,12 @@ public:
_file->seek(start); _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"); Q_ASSERT(!"write to read only device");
return 0; return 0;
} }
virtual qint64 readData(char* data, qint64 maxlen) { virtual qint64 readData(char* data, qint64 maxlen) Q_DECL_OVERRIDE {
maxlen = qMin(maxlen, chunkSize() - _read); maxlen = qMin(maxlen, chunkSize() - _read);
if (maxlen == 0) if (maxlen == 0)
return 0; return 0;
@ -145,25 +145,25 @@ public:
return ret; return ret;
} }
virtual bool atEnd() const { virtual bool atEnd() const Q_DECL_OVERRIDE {
return _read >= chunkSize() || _file->atEnd(); return _read >= chunkSize() || _file->atEnd();
} }
virtual qint64 size() const{ virtual qint64 size() const Q_DECL_OVERRIDE{
return _size; return _size;
} }
qint64 bytesAvailable() const qint64 bytesAvailable() const Q_DECL_OVERRIDE
{ {
return _size - _read + QIODevice::bytesAvailable(); return _size - _read + QIODevice::bytesAvailable();
} }
// random access, we can seek // random access, we can seek
virtual bool isSequential() const{ virtual bool isSequential() const Q_DECL_OVERRIDE{
return false; return false;
} }
virtual bool seek ( qint64 pos ) { virtual bool seek ( qint64 pos ) Q_DECL_OVERRIDE {
_read = pos; _read = pos;
return _file->seek(pos + _start); return _file->seek(pos + _start);
} }

View file

@ -61,9 +61,9 @@ public:
const QMap<QByteArray, QByteArray> &headers, QObject* parent = 0) const QMap<QByteArray, QByteArray> &headers, QObject* parent = 0)
: AbstractNetworkJob(account, path, parent), _device(device), _headers(headers) {} : 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(); emit finishedSignal();
return true; return true;
} }
@ -72,7 +72,7 @@ public:
return _errorString.isEmpty() ? reply()->errorString() : _errorString; return _errorString.isEmpty() ? reply()->errorString() : _errorString;
}; };
virtual void slotTimeout(); virtual void slotTimeout() Q_DECL_OVERRIDE;
signals: signals:
@ -93,11 +93,11 @@ class PropagateUploadFileQNAM : public PropagateItemJob {
public: public:
PropagateUploadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item) PropagateUploadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item)
: PropagateItemJob(propagator, item), _startChunk(0), _currentChunk(0), _chunkCount(0), _transferId(0) {} : PropagateItemJob(propagator, item), _startChunk(0), _currentChunk(0), _chunkCount(0), _transferId(0) {}
void start(); void start() Q_DECL_OVERRIDE;
private slots: private slots:
void slotPutFinished(); void slotPutFinished();
void slotUploadProgress(qint64,qint64); void slotUploadProgress(qint64,qint64);
void abort(); void abort() Q_DECL_OVERRIDE;
void startNextChunk(); void startNextChunk();
void finalize(const Mirall::SyncFileItem&); void finalize(const Mirall::SyncFileItem&);
}; };
@ -123,8 +123,8 @@ public:
const QMap<QByteArray, QByteArray> &headers, const QMap<QByteArray, QByteArray> &headers,
QObject* parent = 0); QObject* parent = 0);
virtual void start(); virtual void start() Q_DECL_OVERRIDE;
virtual bool finished() { virtual bool finished() Q_DECL_OVERRIDE {
emit finishedSignal(); emit finishedSignal();
return true; return true;
} }
@ -135,7 +135,7 @@ public:
SyncFileItem::Status errorStatus() { return _errorStatus; } SyncFileItem::Status errorStatus() { return _errorStatus; }
virtual void slotTimeout(); virtual void slotTimeout() Q_DECL_OVERRIDE;
QByteArray &etag() { return _etag; } QByteArray &etag() { return _etag; }
@ -159,10 +159,10 @@ class PropagateDownloadFileQNAM : public PropagateItemJob {
public: public:
PropagateDownloadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item) PropagateDownloadFileQNAM(OwncloudPropagator* propagator,const SyncFileItem& item)
: PropagateItemJob(propagator, item), _startSize(0) {} : PropagateItemJob(propagator, item), _startSize(0) {}
void start(); void start() Q_DECL_OVERRIDE;
private slots: private slots:
void slotGetFinished(); void slotGetFinished();
void abort(); void abort() Q_DECL_OVERRIDE;
void downloadFinished(); void downloadFinished();
void slotDownloadProgress(qint64,qint64); void slotDownloadProgress(qint64,qint64);

View file

@ -74,26 +74,26 @@ class PropagateLocalRemove : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateLocalRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} PropagateLocalRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
}; };
class PropagateLocalMkdir : public PropagateItemJob { class PropagateLocalMkdir : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateLocalMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} PropagateLocalMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
}; };
class PropagateRemoteRemove : public PropagateNeonJob { class PropagateRemoteRemove : public PropagateNeonJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateRemoteRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} PropagateRemoteRemove (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
}; };
class PropagateRemoteMkdir : public PropagateNeonJob { class PropagateRemoteMkdir : public PropagateNeonJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateRemoteMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} PropagateRemoteMkdir (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
private: private:
static void propfind_results(void *userdata, const ne_uri *uri, const ne_prop_result_set *set); 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; friend class PropagateDirectory; // So it can access the _item;
@ -102,13 +102,13 @@ class PropagateLocalRename : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateLocalRename (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {} PropagateLocalRename (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateItemJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
}; };
class PropagateRemoteRename : public PropagateNeonJob { class PropagateRemoteRename : public PropagateNeonJob {
Q_OBJECT Q_OBJECT
public: public:
PropagateRemoteRename (OwncloudPropagator* propagator,const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} 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 Q_OBJECT
public: public:
UpdateMTimeAndETagJob (OwncloudPropagator* propagator, const SyncFileItem& item) : PropagateNeonJob(propagator, item) {} UpdateMTimeAndETagJob (OwncloudPropagator* propagator, const SyncFileItem& item) : PropagateNeonJob(propagator, item) {}
void start(); void start() Q_DECL_OVERRIDE;
}; };

View file

@ -49,8 +49,8 @@ public slots:
void showActivityPage(); void showActivityPage();
protected: protected:
void reject(); void reject() Q_DECL_OVERRIDE;
void accept(); void accept() Q_DECL_OVERRIDE;
private: private:
Ui::SettingsDialog *_ui; Ui::SettingsDialog *_ui;

View file

@ -33,7 +33,7 @@ class SslErrorDialog;
class SslDialogErrorHandler : public AbstractSslErrorHandler { class SslDialogErrorHandler : public AbstractSslErrorHandler {
public: public:
bool handleErrors(QList<QSslError> errors, QList<QSslCertificate> *certs, Account*); bool handleErrors(QList<QSslError> errors, QList<QSslCertificate> *certs, Account*) Q_DECL_OVERRIDE;
}; };
class SslErrorDialog : public QDialog class SslErrorDialog : public QDialog

View file

@ -20,7 +20,7 @@ class QSslCertificate;
class SimpleSslErrorHandler : public Mirall::AbstractSslErrorHandler { class SimpleSslErrorHandler : public Mirall::AbstractSslErrorHandler {
public: public:
bool handleErrors(QList<QSslError> errors, QList<QSslCertificate> *certs, Mirall::Account*); bool handleErrors(QList<QSslError> errors, QList<QSslCertificate> *certs, Mirall::Account*) Q_DECL_OVERRIDE;
}; };
#endif // SIMPLESSLERRORHANDLER_H #endif // SIMPLESSLERRORHANDLER_H

View file

@ -40,8 +40,8 @@ public:
bool performUpdate(); bool performUpdate();
void checkForUpdate(); void checkForUpdate() Q_DECL_OVERRIDE;
void backgroundCheckForUpdate(); void backgroundCheckForUpdate() Q_DECL_OVERRIDE;
QString statusString() const; QString statusString() const;
int downloadState() const; int downloadState() const;
@ -77,7 +77,7 @@ class NSISUpdater : public OCUpdater {
public: public:
enum UpdateState { NoUpdate = 0, UpdateAvailable, UpdateFailed }; enum UpdateState { NoUpdate = 0, UpdateAvailable, UpdateFailed };
explicit NSISUpdater(const QUrl &url, QObject *parent = 0); explicit NSISUpdater(const QUrl &url, QObject *parent = 0);
bool handleStartup(); bool handleStartup() Q_DECL_OVERRIDE;
private slots: private slots:
void slotSetSeenVersion(); void slotSetSeenVersion();
void slotDownloadFinished(); void slotDownloadFinished();
@ -85,7 +85,7 @@ private slots:
private: private:
NSISUpdater::UpdateState updateStateOnStart(); NSISUpdater::UpdateState updateStateOnStart();
void showDialog(const UpdateInfo &info); void showDialog(const UpdateInfo &info);
void versionInfoArrived(const UpdateInfo &info); void versionInfoArrived(const UpdateInfo &info) Q_DECL_OVERRIDE;
QScopedPointer<QTemporaryFile> _file; QScopedPointer<QTemporaryFile> _file;
QString _targetFile; QString _targetFile;
bool _showFallbackMessage; bool _showFallbackMessage;
@ -98,10 +98,10 @@ class PassiveUpdateNotifier : public OCUpdater {
Q_OBJECT Q_OBJECT
public: public:
explicit PassiveUpdateNotifier(const QUrl &url, QObject *parent = 0); explicit PassiveUpdateNotifier(const QUrl &url, QObject *parent = 0);
bool handleStartup() { return false; } bool handleStartup() Q_DECL_OVERRIDE { return false; }
private: private:
void versionInfoArrived(const UpdateInfo &info); void versionInfoArrived(const UpdateInfo &info) Q_DECL_OVERRIDE;
}; };

View file

@ -26,9 +26,9 @@ public:
~SparkleUpdater(); ~SparkleUpdater();
// unused in this updater // unused in this updater
void checkForUpdate(); void checkForUpdate() Q_DECL_OVERRIDE;
void backgroundCheckForUpdate(); void backgroundCheckForUpdate() Q_DECL_OVERRIDE;
bool handleStartup() { return false; } bool handleStartup() Q_DECL_OVERRIDE { return false; }
private: private:
class Private; class Private;
Private *d; Private *d;

View file

@ -24,7 +24,7 @@ class AbstractCredentials;
class AbstractCredentialsWizardPage : public QWizardPage class AbstractCredentialsWizardPage : public QWizardPage
{ {
public: public:
void cleanupPage(); void cleanupPage() Q_DECL_OVERRIDE;
virtual AbstractCredentials* getCredentials() const = 0; virtual AbstractCredentials* getCredentials() const = 0;
}; };

View file

@ -31,10 +31,10 @@ class OwncloudAdvancedSetupPage: public QWizardPage
public: public:
OwncloudAdvancedSetupPage(); OwncloudAdvancedSetupPage();
virtual bool isComplete() const; virtual bool isComplete() const Q_DECL_OVERRIDE;
virtual void initializePage(); virtual void initializePage() Q_DECL_OVERRIDE;
virtual int nextId() const; virtual int nextId() const Q_DECL_OVERRIDE;
bool validatePage(); bool validatePage() Q_DECL_OVERRIDE;
QString localFolder() const; QString localFolder() const;
void setRemoteFolder( const QString& remoteFolder); void setRemoteFolder( const QString& remoteFolder);
void setMultipleFoldersExist( bool exist ); void setMultipleFoldersExist( bool exist );

View file

@ -30,12 +30,12 @@ class OwncloudHttpCredsPage : public AbstractCredentialsWizardPage
public: public:
OwncloudHttpCredsPage(); OwncloudHttpCredsPage();
AbstractCredentials* getCredentials() const; AbstractCredentials* getCredentials() const Q_DECL_OVERRIDE;
void initializePage(); void initializePage() Q_DECL_OVERRIDE;
void cleanupPage(); void cleanupPage() Q_DECL_OVERRIDE;
bool validatePage(); bool validatePage() Q_DECL_OVERRIDE;
int nextId() const; int nextId() const Q_DECL_OVERRIDE;
void setConnected(bool connected); void setConnected(bool connected);
void setErrorString( const QString& err ); void setErrorString( const QString& err );
void setConfigExists(bool config); void setConfigExists(bool config);

View file

@ -33,12 +33,12 @@ class OwncloudSetupPage: public QWizardPage
public: public:
OwncloudSetupPage(); OwncloudSetupPage();
virtual bool isComplete() const; virtual bool isComplete() const Q_DECL_OVERRIDE;
virtual void initializePage(); virtual void initializePage() Q_DECL_OVERRIDE;
virtual int nextId() const; virtual int nextId() const Q_DECL_OVERRIDE;
void setServerUrl( const QString& ); void setServerUrl( const QString& );
void setAllowPasswordStorage( bool ); void setAllowPasswordStorage( bool );
bool validatePage(); bool validatePage() Q_DECL_OVERRIDE;
QString url() const; QString url() const;
QString localFolder() const; QString localFolder() const;
void setRemoteFolder( const QString& remoteFolder); void setRemoteFolder( const QString& remoteFolder);

View file

@ -33,17 +33,17 @@ class OwncloudShibbolethCredsPage : public AbstractCredentialsWizardPage
public: public:
OwncloudShibbolethCredsPage(); OwncloudShibbolethCredsPage();
AbstractCredentials* getCredentials() const; AbstractCredentials* getCredentials() const Q_DECL_OVERRIDE;
void initializePage(); void initializePage() Q_DECL_OVERRIDE;
int nextId() const; int nextId() const Q_DECL_OVERRIDE;
void setConnected(); void setConnected();
Q_SIGNALS: Q_SIGNALS:
void connectToOCUrl(const QString&); void connectToOCUrl(const QString&);
public Q_SLOTS: public Q_SLOTS:
void setVisible(bool visible); void setVisible(bool visible) Q_DECL_OVERRIDE;
private Q_SLOTS: private Q_SLOTS:
void slotShibbolethCookieReceived(const QNetworkCookie&, Account*); void slotShibbolethCookieReceived(const QNetworkCookie&, Account*);

View file

@ -29,8 +29,8 @@ public:
OwncloudWizardResultPage(); OwncloudWizardResultPage();
~OwncloudWizardResultPage(); ~OwncloudWizardResultPage();
bool isComplete() const; bool isComplete() const Q_DECL_OVERRIDE;
void initializePage(); void initializePage() Q_DECL_OVERRIDE;
void setRemoteFolder( const QString& remoteFolder); void setRemoteFolder( const QString& remoteFolder);
public slots: public slots: