diff options
Diffstat (limited to 'src/qml/qml/qqmlobjectcreator.cpp')
-rw-r--r-- | src/qml/qml/qqmlobjectcreator.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/src/qml/qml/qqmlobjectcreator.cpp b/src/qml/qml/qqmlobjectcreator.cpp index e7a08773f4..4c86e6a307 100644 --- a/src/qml/qml/qqmlobjectcreator.cpp +++ b/src/qml/qml/qqmlobjectcreator.cpp @@ -192,17 +192,7 @@ QObject *QQmlObjectCreator::create(int subComponentIndex, QObject *parent, QQmlI if (topLevelCreator) sharedState->allJavaScriptObjects = scope.alloc(compiledData->totalObjectCount); - QVector<QQmlContextData::ObjectIdMapping> mapping(objectIndexToId.count()); - for (QHash<int, int>::ConstIterator it = objectIndexToId.constBegin(), end = objectIndexToId.constEnd(); - it != end; ++it) { - const QV4::CompiledData::Object *obj = qmlUnit->objectAt(it.key()); - - QQmlContextData::ObjectIdMapping m; - m.id = it.value(); - m.name = stringAt(obj->idIndex); - mapping[m.id] = m; - } - context->setIdPropertyData(mapping); + context->setIdPropertyData(objectIndexToId); if (subComponentIndex == -1 && compiledData->scripts.count()) { QV4::ScopedObject scripts(scope, v4->newArrayObject(compiledData->scripts.count())); |