QmlDesigner.MetaInfo: Resolve properties using the CppComponentValue

If the type is still "unknown" use the CppComponentValue
to resolve the type.

Change-Id: Ib404faa89a06d93f34189abfc7427122567ff25a
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
This commit is contained in:
Thomas Hartmann
2016-07-12 16:22:36 +02:00
parent 2cbd4ed0dd
commit a5cc7e3c7b

View File

@@ -441,6 +441,10 @@ QVector<PropertyInfo> getQmlTypes(const CppComponentValue *objectValue, const Co
TypeName type = property.second; TypeName type = property.second;
if (!objectValue->isPointer(nameAsString) && !objectValue->isListProperty(nameAsString)) if (!objectValue->isPointer(nameAsString) && !objectValue->isListProperty(nameAsString))
type = objectValue->propertyType(nameAsString).toUtf8(); type = objectValue->propertyType(nameAsString).toUtf8();
if (type == "unknown" && objectValue->hasProperty(nameAsString))
type = objectValue->propertyType(nameAsString).toUtf8();
propertyList.append(qMakePair(name, type)); propertyList.append(qMakePair(name, type));
} }