summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Funk <kfunk@kde.org>2017-09-20 20:57:30 +0200
committerKevin Funk <kevin.funk@kdab.com>2017-09-22 14:31:08 +0000
commit7c9db49830de90879ecf7a217386cc860c9eb206 (patch)
tree6f2e57379c363acca3deb85cbb9cbd06c100df33
parent40d2a4a2170ea2973f972fa57d3cef19518ac51a (diff)
Replace Q_DECL_OVERRIDE with override
Change-Id: Iaf72bd006af026255bc5cd1ecf14f187db1bcf52 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
-rw-r--r--examples/activeqt/webbrowser/webaxwidget.h2
-rw-r--r--src/activeqt/container/qaxobject.h10
-rw-r--r--src/activeqt/container/qaxscript.h2
-rw-r--r--src/activeqt/container/qaxwidget.cpp2
-rw-r--r--src/activeqt/container/qaxwidget.h22
-rw-r--r--src/activeqt/control/qaxaggregated.h6
-rw-r--r--src/activeqt/control/qaxfactory.h34
-rw-r--r--src/activeqt/control/qaxserverbase.cpp2
-rw-r--r--tools/testcon/mainwindow.h2
9 files changed, 41 insertions, 41 deletions
diff --git a/examples/activeqt/webbrowser/webaxwidget.h b/examples/activeqt/webbrowser/webaxwidget.h
index acb936e..ffd90f8 100644
--- a/examples/activeqt/webbrowser/webaxwidget.h
+++ b/examples/activeqt/webbrowser/webaxwidget.h
@@ -53,7 +53,7 @@ public:
{
}
protected:
- bool translateKeyEvent(int message, int keycode) const Q_DECL_OVERRIDE
+ bool translateKeyEvent(int message, int keycode) const override
{
if (message >= WM_KEYFIRST && message <= WM_KEYLAST)
return true;
diff --git a/src/activeqt/container/qaxobject.h b/src/activeqt/container/qaxobject.h
index f7e16d2..0eeda2d 100644
--- a/src/activeqt/container/qaxobject.h
+++ b/src/activeqt/container/qaxobject.h
@@ -50,8 +50,8 @@ class QAxObject : public QObject, public QAxBase
friend class QAxEventSink;
Q_OBJECT_FAKE
public:
- QObject* qObject() const Q_DECL_OVERRIDE { return static_cast<QObject *>(const_cast<QAxObject *>(this)); }
- const char *className() const Q_DECL_OVERRIDE;
+ QObject* qObject() const override { return static_cast<QObject *>(const_cast<QAxObject *>(this)); }
+ const char *className() const override;
explicit QAxObject(QObject *parent = Q_NULLPTR);
explicit QAxObject(const QString &c, QObject *parent = Q_NULLPTR);
@@ -61,11 +61,11 @@ public:
bool doVerb(const QString &verb);
protected:
- void connectNotify(const QMetaMethod &signal) Q_DECL_OVERRIDE;
- const QMetaObject *fallbackMetaObject() const Q_DECL_OVERRIDE;
+ void connectNotify(const QMetaMethod &signal) override;
+ const QMetaObject *fallbackMetaObject() const override;
private:
- const QMetaObject *parentMetaObject() const Q_DECL_OVERRIDE;
+ const QMetaObject *parentMetaObject() const override;
};
template <> inline QAxObject *qobject_cast<QAxObject*>(const QObject *o)
diff --git a/src/activeqt/container/qaxscript.h b/src/activeqt/container/qaxscript.h
index 67c94da..d0aafaa 100644
--- a/src/activeqt/container/qaxscript.h
+++ b/src/activeqt/container/qaxscript.h
@@ -82,7 +82,7 @@ public:
long queryInterface(const QUuid &, void**) const;
protected:
- bool initialize(IUnknown** ptr) Q_DECL_OVERRIDE;
+ bool initialize(IUnknown** ptr) override;
private:
QAxScript *script_code;
diff --git a/src/activeqt/container/qaxwidget.cpp b/src/activeqt/container/qaxwidget.cpp
index 3e927f4..8fb659d 100644
--- a/src/activeqt/container/qaxwidget.cpp
+++ b/src/activeqt/container/qaxwidget.cpp
@@ -463,7 +463,7 @@ static const wchar_t *qaxatom = L"QAxContainer4_Atom";
class QAxNativeEventFilter : public QAbstractNativeEventFilter
{
public:
- bool nativeEventFilter(const QByteArray &eventType, void *message, long *) Q_DECL_OVERRIDE;
+ bool nativeEventFilter(const QByteArray &eventType, void *message, long *) override;
};
Q_GLOBAL_STATIC(QAxNativeEventFilter, s_nativeEventFilter)
diff --git a/src/activeqt/container/qaxwidget.h b/src/activeqt/container/qaxwidget.h
index e6131d9..6c8d4b9 100644
--- a/src/activeqt/container/qaxwidget.h
+++ b/src/activeqt/container/qaxwidget.h
@@ -56,40 +56,40 @@ class QAxWidget : public QWidget, public QAxBase
{
Q_OBJECT_FAKE
public:
- QObject* qObject() const Q_DECL_OVERRIDE { return const_cast<QAxWidget *>(this); }
- const char *className() const Q_DECL_OVERRIDE;
+ QObject* qObject() const override { return const_cast<QAxWidget *>(this); }
+ const char *className() const override;
explicit QAxWidget(QWidget* parent = Q_NULLPTR, Qt::WindowFlags f = Qt::WindowFlags());
explicit QAxWidget(const QString &c, QWidget *parent = Q_NULLPTR, Qt::WindowFlags f = Qt::WindowFlags());
explicit QAxWidget(IUnknown *iface, QWidget *parent = Q_NULLPTR, Qt::WindowFlags f = Qt::WindowFlags());
~QAxWidget();
- void clear() Q_DECL_OVERRIDE;
+ void clear() override;
bool doVerb(const QString &verb);
- QSize sizeHint() const Q_DECL_OVERRIDE;
- QSize minimumSizeHint() const Q_DECL_OVERRIDE;
+ QSize sizeHint() const override;
+ QSize minimumSizeHint() const override;
virtual QAxAggregated *createAggregate();
protected:
- bool initialize(IUnknown **) Q_DECL_OVERRIDE;
+ bool initialize(IUnknown **) override;
virtual bool createHostWindow(bool);
bool createHostWindow(bool, const QByteArray&);
- void changeEvent(QEvent *e) Q_DECL_OVERRIDE;
- void resizeEvent(QResizeEvent *) Q_DECL_OVERRIDE;
+ void changeEvent(QEvent *e) override;
+ void resizeEvent(QResizeEvent *) override;
virtual bool translateKeyEvent(int message, int keycode) const;
- void connectNotify(const QMetaMethod &signal) Q_DECL_OVERRIDE;
- const QMetaObject *fallbackMetaObject() const Q_DECL_OVERRIDE;
+ void connectNotify(const QMetaMethod &signal) override;
+ const QMetaObject *fallbackMetaObject() const override;
private:
friend class QAxClientSite;
QAxClientSite *container;
QAxWidgetPrivate *d;
- const QMetaObject *parentMetaObject() const Q_DECL_OVERRIDE;
+ const QMetaObject *parentMetaObject() const override;
};
template <> inline QAxWidget *qobject_cast<QAxWidget*>(const QObject *o)
diff --git a/src/activeqt/control/qaxaggregated.h b/src/activeqt/control/qaxaggregated.h
index 80e0212..77e33dc 100644
--- a/src/activeqt/control/qaxaggregated.h
+++ b/src/activeqt/control/qaxaggregated.h
@@ -73,10 +73,10 @@ private:
};
#define QAXAGG_IUNKNOWN \
- HRESULT WINAPI QueryInterface(REFIID iid, LPVOID *iface) Q_DECL_OVERRIDE \
+ HRESULT WINAPI QueryInterface(REFIID iid, LPVOID *iface) override \
{ return controllingUnknown()->QueryInterface(iid, iface); } \
- ULONG WINAPI AddRef() Q_DECL_OVERRIDE { return controllingUnknown()->AddRef(); } \
- ULONG WINAPI Release() Q_DECL_OVERRIDE { return controllingUnknown()->Release(); } \
+ ULONG WINAPI AddRef() override { return controllingUnknown()->AddRef(); } \
+ ULONG WINAPI Release() override { return controllingUnknown()->Release(); } \
QT_END_NAMESPACE
diff --git a/src/activeqt/control/qaxfactory.h b/src/activeqt/control/qaxfactory.h
index 2f7bed1..5c1df48 100644
--- a/src/activeqt/control/qaxfactory.h
+++ b/src/activeqt/control/qaxfactory.h
@@ -189,9 +189,9 @@ public:
: QAxFactory(libId, appId)
{}
- const QMetaObject *metaObject(const QString &) const Q_DECL_OVERRIDE { return &T::staticMetaObject; }
- QStringList featureList() const Q_DECL_OVERRIDE { return QStringList(QLatin1String(T::staticMetaObject.className())); }
- QObject *createObject(const QString &key) Q_DECL_OVERRIDE
+ const QMetaObject *metaObject(const QString &) const override { return &T::staticMetaObject; }
+ QStringList featureList() const override { return QStringList(QLatin1String(T::staticMetaObject.className())); }
+ QObject *createObject(const QString &key) override
{
const QMetaObject &mo = T::staticMetaObject;
if (key != QLatin1String(mo.className()))
@@ -201,7 +201,7 @@ public:
return new T(Q_NULLPTR);
}
- void registerClass(const QString &key, QSettings *settings) const Q_DECL_OVERRIDE
+ void registerClass(const QString &key, QSettings *settings) const override
{
const QStringList categories = getImplementedCategories();
@@ -212,7 +212,7 @@ public:
}
}
- void unregisterClass(const QString &key, QSettings *settings) const Q_DECL_OVERRIDE
+ void unregisterClass(const QString &key, QSettings *settings) const override
{
const QStringList categories = getImplementedCategories();
@@ -269,47 +269,47 @@ private:
#define QAXFACTORY_END() \
} \
- ~QAxFactoryList() Q_DECL_OVERRIDE { qDeleteAll(factories); } \
- QStringList featureList() const Q_DECL_OVERRIDE { return factoryKeys; } \
- const QMetaObject *metaObject(const QString&key) const Q_DECL_OVERRIDE { \
+ ~QAxFactoryList() override { qDeleteAll(factories); } \
+ QStringList featureList() const override { return factoryKeys; } \
+ const QMetaObject *metaObject(const QString&key) const override { \
QAxFactory *f = factories[key]; \
return f ? f->metaObject(key) : Q_NULLPTR; \
} \
- QObject *createObject(const QString &key) Q_DECL_OVERRIDE { \
+ QObject *createObject(const QString &key) override { \
if (!creatable.value(key)) \
return Q_NULLPTR; \
QAxFactory *f = factories[key]; \
return f ? f->createObject(key) : Q_NULLPTR; \
} \
- QUuid classID(const QString &key) const Q_DECL_OVERRIDE { \
+ QUuid classID(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->classID(key) : QUuid(); \
} \
- QUuid interfaceID(const QString &key) const Q_DECL_OVERRIDE { \
+ QUuid interfaceID(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->interfaceID(key) : QUuid(); \
} \
- QUuid eventsID(const QString &key) const Q_DECL_OVERRIDE { \
+ QUuid eventsID(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->eventsID(key) : QUuid(); \
} \
- void registerClass(const QString &key, QSettings *s) const Q_DECL_OVERRIDE { \
+ void registerClass(const QString &key, QSettings *s) const override { \
QAxFactory *f = factories.value(key); \
if (f) f->registerClass(key, s); \
} \
- void unregisterClass(const QString &key, QSettings *s) const Q_DECL_OVERRIDE { \
+ void unregisterClass(const QString &key, QSettings *s) const override { \
QAxFactory *f = factories.value(key); \
if (f) f->unregisterClass(key, s); \
} \
- QString exposeToSuperClass(const QString &key) const Q_DECL_OVERRIDE { \
+ QString exposeToSuperClass(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->exposeToSuperClass(key) : QString(); \
} \
- bool stayTopLevel(const QString &key) const Q_DECL_OVERRIDE { \
+ bool stayTopLevel(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->stayTopLevel(key) : false; \
} \
- bool hasStockEvents(const QString &key) const Q_DECL_OVERRIDE { \
+ bool hasStockEvents(const QString &key) const override { \
QAxFactory *f = factories.value(key); \
return f ? f->hasStockEvents(key) : false; \
} \
diff --git a/src/activeqt/control/qaxserverbase.cpp b/src/activeqt/control/qaxserverbase.cpp
index 779f015..0cde5e2 100644
--- a/src/activeqt/control/qaxserverbase.cpp
+++ b/src/activeqt/control/qaxserverbase.cpp
@@ -804,7 +804,7 @@ LRESULT QT_WIN_CALLBACK axs_FilterProc(int nCode, WPARAM wParam, LPARAM lParam)
class QAxWinEventFilter : public QAbstractNativeEventFilter
{
public:
- bool nativeEventFilter(const QByteArray &, void *message, long *) Q_DECL_OVERRIDE;
+ bool nativeEventFilter(const QByteArray &, void *message, long *) override;
};
bool QAxWinEventFilter::nativeEventFilter(const QByteArray &, void *message, long *)
diff --git a/tools/testcon/mainwindow.h b/tools/testcon/mainwindow.h
index 84cd2ce..7e6575b 100644
--- a/tools/testcon/mainwindow.h
+++ b/tools/testcon/mainwindow.h
@@ -59,7 +59,7 @@ public:
bool loadScript(const QString &file);
protected:
- void closeEvent(QCloseEvent *) Q_DECL_OVERRIDE;
+ void closeEvent(QCloseEvent *) override;
public slots:
void appendLogText(const QString &);