From 7a4967986ed5cfa3418bdd53a8ea8a34e100241a Mon Sep 17 00:00:00 2001 From: Frank Meerkoetter Date: Mon, 20 Jul 2015 20:35:34 +0200 Subject: Port list properties away from QQmlVmeVariant The index into the list of list properties (an int) is now also stored as a QV4::Value. Change-Id: I16809c5027ed3c4264aab6dfed8b4519adf83e2a Reviewed-by: Simon Hausmann --- src/qml/qml/qqmlvmemetaobject.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qml/qml/qqmlvmemetaobject.cpp b/src/qml/qml/qqmlvmemetaobject.cpp index d4ad0f2a9a..1e60b593f1 100644 --- a/src/qml/qml/qqmlvmemetaobject.cpp +++ b/src/qml/qml/qqmlvmemetaobject.cpp @@ -546,7 +546,7 @@ QQmlVMEMetaObject::QQmlVMEMetaObject(QObject *obj, int t = (metaData->propertyData() + ii)->propertyType; if (t == list_type) { listProperties.append(List(methodOffset() + ii, this)); - data[ii].setValue(listProperties.count() - 1); + writeProperty(ii, listProperties.count() - 1); } else if (!needsJSWrapper && (t == qobject_type || t == variant_type)) { needsJSWrapper = true; } @@ -993,7 +993,7 @@ int QQmlVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a) break; } if (t == qMetaTypeId >()) { - int listIndex = data[id].asInt(); + const int listIndex = readPropertyAsInt(id); const List *list = &listProperties.at(listIndex); *reinterpret_cast *>(a[0]) = QQmlListProperty(object, const_cast(list), -- cgit v1.2.3