summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2017-12-01 08:52:48 +0100
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2017-12-14 07:33:25 +0000
commit78f77f80057b1e77c3f47d52de3e0b3f0c5d8d6e (patch)
treece515e214a49d07c53d5f4bc09c7f8f948cd2eea
parentc2e8b0dc4ddaaea9d20175cddea352e39f26896e (diff)
Quick3DNodeInstantiatorPrivate: Fix build after private API change
qtdeclarative/60d589ccddb036e84883a6c2ef63a5292c8ad022 changed QQmlInstanceModel::object() to take an enumeration. Task-number: QTBUG-61537 Change-Id: I2fab7e80b728f9265e201f47614a79167199667f Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
-rw-r--r--src/quick3d/quick3d/items/quick3dnodeinstantiator.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/quick3d/quick3d/items/quick3dnodeinstantiator.cpp b/src/quick3d/quick3d/items/quick3dnodeinstantiator.cpp
index b99f6ae75..21f58e56d 100644
--- a/src/quick3d/quick3d/items/quick3dnodeinstantiator.cpp
+++ b/src/quick3d/quick3d/items/quick3dnodeinstantiator.cpp
@@ -135,7 +135,8 @@ void Quick3DNodeInstantiatorPrivate::regenerate()
}
for (int i = 0; i < m_instanceModel->count(); i++) {
- QObject *object = m_instanceModel->object(i, m_async);
+ QObject *object = m_instanceModel->object(i, m_async ?
+ QQmlIncubator::Asynchronous : QQmlIncubator::AsynchronousIfNested);
// If the item was already created we won't get a createdItem
if (object)
_q_createdItem(i, object);
@@ -202,7 +203,8 @@ void Quick3DNodeInstantiatorPrivate::_q_modelUpdated(const QQmlChangeSet &change
m_objects = m_objects.mid(0, index) + movedObjects + m_objects.mid(index);
} else for (int i = 0; i < insert.count; ++i) {
int modelIndex = index + i;
- QObject *obj = m_instanceModel->object(modelIndex, m_async);
+ QObject *obj = m_instanceModel->object(modelIndex, m_async ?
+ QQmlIncubator::Asynchronous : QQmlIncubator::AsynchronousIfNested);
if (obj)
_q_createdItem(modelIndex, obj);
}