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/widgets/itemviews/qcolumnview_p.h | |
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/widgets/itemviews/qcolumnview_p.h')
-rw-r--r-- | src/widgets/itemviews/qcolumnview_p.h | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/widgets/itemviews/qcolumnview_p.h b/src/widgets/itemviews/qcolumnview_p.h index fa276075fe..850ab02747 100644 --- a/src/widgets/itemviews/qcolumnview_p.h +++ b/src/widgets/itemviews/qcolumnview_p.h @@ -80,7 +80,7 @@ public: setMinimumWidth(previewWidget->minimumWidth()); } - void resizeEvent(QResizeEvent * event) Q_DECL_OVERRIDE{ + void resizeEvent(QResizeEvent * event) override{ if (!previewWidget) return; previewWidget->resize( @@ -96,7 +96,7 @@ public: QAbstractScrollArea::resizeEvent(event); } - void scrollContentsBy(int dx, int dy) Q_DECL_OVERRIDE + void scrollContentsBy(int dx, int dy) override { if (!previewWidget) return; @@ -106,36 +106,36 @@ public: QAbstractItemView::scrollContentsBy(dx, dy); } - QRect visualRect(const QModelIndex &) const Q_DECL_OVERRIDE + QRect visualRect(const QModelIndex &) const override { return QRect(); } - void scrollTo(const QModelIndex &, ScrollHint) Q_DECL_OVERRIDE + void scrollTo(const QModelIndex &, ScrollHint) override { } - QModelIndex indexAt(const QPoint &) const Q_DECL_OVERRIDE + QModelIndex indexAt(const QPoint &) const override { return QModelIndex(); } - QModelIndex moveCursor(CursorAction, Qt::KeyboardModifiers) Q_DECL_OVERRIDE + QModelIndex moveCursor(CursorAction, Qt::KeyboardModifiers) override { return QModelIndex(); } - int horizontalOffset () const Q_DECL_OVERRIDE { + int horizontalOffset () const override { return 0; } - int verticalOffset () const Q_DECL_OVERRIDE { + int verticalOffset () const override { return 0; } - QRegion visualRegionForSelection(const QItemSelection &) const Q_DECL_OVERRIDE + QRegion visualRegionForSelection(const QItemSelection &) const override { return QRegion(); } - bool isIndexHidden(const QModelIndex &) const Q_DECL_OVERRIDE + bool isIndexHidden(const QModelIndex &) const override { return false; } - void setSelection(const QRect &, QItemSelectionModel::SelectionFlags) Q_DECL_OVERRIDE + void setSelection(const QRect &, QItemSelectionModel::SelectionFlags) override { } private: @@ -163,7 +163,7 @@ public: void _q_gripMoved(int offset); void _q_changeCurrentColumn(); void _q_clicked(const QModelIndex &index); - void _q_columnsInserted(const QModelIndex &parent, int start, int end) Q_DECL_OVERRIDE; + void _q_columnsInserted(const QModelIndex &parent, int start, int end) override; QList<QAbstractItemView*> columns; QVector<int> columnSizes; // used during init and corner moving @@ -188,7 +188,7 @@ public: void paint(QPainter *painter, const QStyleOptionViewItem &option, - const QModelIndex &index) const Q_DECL_OVERRIDE; + const QModelIndex &index) const override; }; QT_END_NAMESPACE |