aboutsummaryrefslogtreecommitdiffstats
path: root/src/imports/xmllistmodel/qqmlxmllistmodel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/imports/xmllistmodel/qqmlxmllistmodel.cpp')
-rw-r--r--src/imports/xmllistmodel/qqmlxmllistmodel.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/imports/xmllistmodel/qqmlxmllistmodel.cpp b/src/imports/xmllistmodel/qqmlxmllistmodel.cpp
index 97dc3aba1f..0b9be3105b 100644
--- a/src/imports/xmllistmodel/qqmlxmllistmodel.cpp
+++ b/src/imports/xmllistmodel/qqmlxmllistmodel.cpp
@@ -44,7 +44,7 @@
#include <qqmlcontext.h>
#include <private/qqmlengine_p.h>
#include <private/qv8engine_p.h>
-#include <private/qv4value_p.h>
+#include <private/qv4value_inl_p.h>
#include <private/qv4engine_p.h>
#include <private/qv4object_p.h>
@@ -925,10 +925,12 @@ QQmlV4Handle QQuickXmlListModel::get(int index) const
ExecutionEngine *v4engine = QV8Engine::getV4(v8engine);
Scope scope(v4engine);
Scoped<Object> o(scope, v4engine->newObject());
+ ScopedString name(scope);
+ ScopedValue value(scope);
for (int ii = 0; ii < d->roleObjects.count(); ++ii) {
- ScopedString name(scope, v4engine->newIdentifier(d->roleObjects[ii]->name()));
- Property *p = o->insertMember(name, PropertyAttributes());
- p->value = v8engine->fromVariant(d->data.value(ii).value(index));
+ name = v4engine->newIdentifier(d->roleObjects[ii]->name());
+ value = v8engine->fromVariant(d->data.value(ii).value(index));
+ o->insertMember(name, value);
}
return QQmlV4Handle(o);