summaryrefslogtreecommitdiffstats
path: root/src/core/transforms/qtransform.cpp
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-09-24 03:00:47 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-09-24 03:00:54 +0200
commitc5f12acd27dee5fdec38b78a02a95cf7debfe9a5 (patch)
tree0dbb89ecc77e9401eb3f2200dcbc9f3a6ea9dd68 /src/core/transforms/qtransform.cpp
parent4106737900476f9c98325252ec9fedcad602af92 (diff)
parent25ecd0881ded8e4f265a4eb01ab775eafcee65d8 (diff)
Merge "Merge remote-tracking branch 'origin/5.15' into dev"
Diffstat (limited to 'src/core/transforms/qtransform.cpp')
-rw-r--r--src/core/transforms/qtransform.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/core/transforms/qtransform.cpp b/src/core/transforms/qtransform.cpp
index bedf108f2..e5902f11f 100644
--- a/src/core/transforms/qtransform.cpp
+++ b/src/core/transforms/qtransform.cpp
@@ -239,12 +239,13 @@ QTransform::QTransform(QTransformPrivate &dd, QNode *parent)
*/
void QTransform::sceneChangeEvent(const QSceneChangePtr &change)
{
+ Q_D(QTransform);
switch (change->type()) {
case PropertyUpdated: {
Qt3DCore::QPropertyUpdatedChangePtr propertyChange = qSharedPointerCast<Qt3DCore::QPropertyUpdatedChange>(change);
if (propertyChange->propertyName() == QByteArrayLiteral("worldMatrix")) {
const bool blocked = blockNotifications(true);
- setWorldMatrix(propertyChange->value().value<QMatrix4x4>());
+ d->setWorldMatrix(propertyChange->value().value<QMatrix4x4>());
blockNotifications(blocked);
}
break;
@@ -254,13 +255,13 @@ void QTransform::sceneChangeEvent(const QSceneChangePtr &change)
}
}
-void QTransform::setWorldMatrix(const QMatrix4x4 &worldMatrix)
+void QTransformPrivate::setWorldMatrix(const QMatrix4x4 &worldMatrix)
{
- Q_D(QTransform);
- if (d->m_worldMatrix == worldMatrix)
+ Q_Q(QTransform);
+ if (m_worldMatrix == worldMatrix)
return;
- d->m_worldMatrix = worldMatrix;
- emit worldMatrixChanged(worldMatrix);
+ m_worldMatrix = worldMatrix;
+ emit q->worldMatrixChanged(worldMatrix);
}
void QTransform::setMatrix(const QMatrix4x4 &m)