From 77215f1219c6146c5d58fc21d4d8940ee477a6d7 Mon Sep 17 00:00:00 2001 From: Andy Nichols Date: Mon, 13 Nov 2017 14:42:48 +0100 Subject: Fix warnings caused by QClipAnimator calling QNode::sceneChangeEvent Calling the base implementation of sceneChangeEvent unnecessarily can cause lots of warnings to be printed: "sceneChangeEvent should have been subclassed" To prevent this (and still work around the bug this line intended to fix) a conditional has been added to make sure that we do not hit the warning condition. Change-Id: Ibaa771b4b58d6f4e38ba815bde1b635ed83867d2 Reviewed-by: Sean Harmer --- src/animation/frontend/qclipanimator.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/animation/frontend/qclipanimator.cpp b/src/animation/frontend/qclipanimator.cpp index 79125a76e..6b503e87f 100644 --- a/src/animation/frontend/qclipanimator.cpp +++ b/src/animation/frontend/qclipanimator.cpp @@ -174,8 +174,9 @@ void QClipAnimator::sceneChangeEvent(const Qt3DCore::QSceneChangePtr &change) QAnimationCallbackTriggerPtr callbackTrigger = qSharedPointerCast(change); if (callbackTrigger->callback()) callbackTrigger->callback()->valueChanged(callbackTrigger->value()); + } else if (change->type() == Qt3DCore::PropertyUpdated) { + QAbstractClipAnimator::sceneChangeEvent(change); } - QAbstractClipAnimator::sceneChangeEvent(change); } } // namespace Qt3DAnimation -- cgit v1.2.3