From 84bb134397f9a48b1b5bd57d24e5c0410290e2ce Mon Sep 17 00:00:00 2001 From: Kevin Funk Date: Thu, 21 Sep 2017 12:23:08 +0200 Subject: Disambiguate QQuickStateActionEvent::override Don't use override as function name, may create confusion with the official override specifier since C++11 Rename method to QQuickStateActionEvent::mayOverride Change-Id: I1f34ec1127cc3e7c529b7e0aa3272fbfed553fa1 Reviewed-by: Lars Knoll --- src/quick/util/qquickpropertychanges.cpp | 2 +- src/quick/util/qquickstate.cpp | 6 +++--- src/quick/util/qquickstate_p.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src/quick/util') diff --git a/src/quick/util/qquickpropertychanges.cpp b/src/quick/util/qquickpropertychanges.cpp index 61380b3ea0..4a9b4a95c1 100644 --- a/src/quick/util/qquickpropertychanges.cpp +++ b/src/quick/util/qquickpropertychanges.cpp @@ -180,7 +180,7 @@ public: rewindExpression = QQmlPropertyPrivate::signalExpression(property); } - bool override(QQuickStateActionEvent *other) override { + bool mayOverride(QQuickStateActionEvent *other) override { if (other == this) return true; if (other->type() != type()) diff --git a/src/quick/util/qquickstate.cpp b/src/quick/util/qquickstate.cpp index 0a49d41491..65e51feb81 100644 --- a/src/quick/util/qquickstate.cpp +++ b/src/quick/util/qquickstate.cpp @@ -106,7 +106,7 @@ void QQuickStateActionEvent::clearBindings() { } -bool QQuickStateActionEvent::override(QQuickStateActionEvent *other) +bool QQuickStateActionEvent::mayOverride(QQuickStateActionEvent *other) { Q_UNUSED(other); return false; @@ -574,7 +574,7 @@ void QQuickState::apply(QQuickTransition *trans, QQuickState *revert) for (int jj = 0; jj < d->revertList.count(); ++jj) { QQuickStateActionEvent *event = d->revertList.at(jj).event(); if (event && event->type() == action.event->type()) { - if (action.event->override(event)) { + if (action.event->mayOverride(event)) { found = true; if (action.event != d->revertList.at(jj).event() && action.event->needsCopy()) { @@ -636,7 +636,7 @@ void QQuickState::apply(QQuickTransition *trans, QQuickState *revert) for (int jj = 0; !found && jj < applyList.count(); ++jj) { const QQuickStateAction &action = applyList.at(jj); if (action.event && action.event->type() == event->type()) { - if (action.event->override(event)) + if (action.event->mayOverride(event)) found = true; } } diff --git a/src/quick/util/qquickstate_p.h b/src/quick/util/qquickstate_p.h index 7d22ca9f8c..ac720f4189 100644 --- a/src/quick/util/qquickstate_p.h +++ b/src/quick/util/qquickstate_p.h @@ -115,7 +115,7 @@ public: virtual bool changesBindings(); virtual void clearBindings(); - virtual bool override(QQuickStateActionEvent*other); + virtual bool mayOverride(QQuickStateActionEvent*other); }; //### rename to QQuickStateChange? -- cgit v1.2.3