diff options
author | Kevin Funk <kevin.funk@kdab.com> | 2017-09-18 10:36:49 +0200 |
---|---|---|
committer | Kevin Funk <kevin.funk@kdab.com> | 2017-09-19 11:53:42 +0000 |
commit | 47c92fbb0b588b443cead18a5aad5a2b5ad9e4d7 (patch) | |
tree | 330914ff8225867e19b9ed5e049813d9f1e5ec08 /src/printsupport/dialogs/qprintpreviewdialog.cpp | |
parent | 93dd85141b35460a83dac86083581ba1c1975927 (diff) |
Replace Q_DECL_OVERRIDE with override where possible
Remaining uses of Q_DECL_OVERRIDE are in:
src/corelib/global/qcompilerdetection.h
src/corelib/global/qglobal.cpp
doc/global/qt-cpp-defines.qdocconf
(definition and documentation of Q_DECL_OVERRIDE)
tests/manual/qcursor/qcursorhighdpi/main.cpp
(a test executable compilable both under Qt4 and Qt5)
Change-Id: Ib9b05d829add69e98a86238274b6a1fcb19b49ba
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Diffstat (limited to 'src/printsupport/dialogs/qprintpreviewdialog.cpp')
-rw-r--r-- | src/printsupport/dialogs/qprintpreviewdialog.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/printsupport/dialogs/qprintpreviewdialog.cpp b/src/printsupport/dialogs/qprintpreviewdialog.cpp index dbcbaf3ce5..171c4f5a23 100644 --- a/src/printsupport/dialogs/qprintpreviewdialog.cpp +++ b/src/printsupport/dialogs/qprintpreviewdialog.cpp @@ -79,7 +79,7 @@ class QPrintPreviewMainWindow : public QMainWindow { public: QPrintPreviewMainWindow(QWidget *parent) : QMainWindow(parent) {} - QMenu *createPopupMenu() Q_DECL_OVERRIDE { return 0; } + QMenu *createPopupMenu() override { return 0; } }; class ZoomFactorValidator : public QDoubleValidator @@ -90,7 +90,7 @@ public: ZoomFactorValidator(qreal bottom, qreal top, int decimals, QObject *parent) : QDoubleValidator(bottom, top, decimals, parent) {} - State validate(QString &input, int &pos) const Q_DECL_OVERRIDE + State validate(QString &input, int &pos) const override { bool replacePercent = false; if (input.endsWith(QLatin1Char('%'))) { @@ -123,13 +123,13 @@ public: } protected: - void focusInEvent(QFocusEvent *e) Q_DECL_OVERRIDE + void focusInEvent(QFocusEvent *e) override { origText = text(); QLineEdit::focusInEvent(e); } - void focusOutEvent(QFocusEvent *e) Q_DECL_OVERRIDE + void focusOutEvent(QFocusEvent *e) override { if (isModified() && !hasAcceptableInput()) setText(origText); |