diff options
author | Michael Brasser <michael.brasser@nokia.com> | 2009-12-17 06:18:56 (GMT) |
---|---|---|
committer | Michael Brasser <michael.brasser@nokia.com> | 2009-12-17 06:31:38 (GMT) |
commit | d169873541ca6f6725e9ce5bfbbf9941f1823a1f (patch) | |
tree | 9b7fd46f2f50caa43751c9042ec1d4ed32b77ded /src/declarative/qml/qmlengine.cpp | |
parent | 2bd2433c606a6ddb745b57776d83f326d85037f5 (diff) | |
download | Qt-d169873541ca6f6725e9ce5bfbbf9941f1823a1f.zip Qt-d169873541ca6f6725e9ce5bfbbf9941f1823a1f.tar.gz Qt-d169873541ca6f6725e9ce5bfbbf9941f1823a1f.tar.bz2 |
Set correct property flags for custom property types.
If a property type was a composite object pointer
(e.g. property MyObject obj), it was not being correctly identified as an
object type.
Task-number: QTBUG-6335
Reviewed-by: Aaron Kennedy
Diffstat (limited to 'src/declarative/qml/qmlengine.cpp')
-rw-r--r-- | src/declarative/qml/qmlengine.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/declarative/qml/qmlengine.cpp b/src/declarative/qml/qmlengine.cpp index 6b66095..f541631 100644 --- a/src/declarative/qml/qmlengine.cpp +++ b/src/declarative/qml/qmlengine.cpp @@ -1527,6 +1527,16 @@ int QmlEnginePrivate::qmlListType(int t) const return QmlMetaType::qmlListType(t); } +QmlMetaType::TypeCategory QmlEnginePrivate::typeCategory(int t) const +{ + if (m_compositeTypes.contains(t)) + return QmlMetaType::Object; + else if (m_qmlLists.contains(t)) + return QmlMetaType::QmlList; + else + return QmlMetaType::typeCategory(t); +} + const QMetaObject *QmlEnginePrivate::rawMetaObjectForType(int t) const { QHash<int, QmlCompiledData*>::ConstIterator iter = m_compositeTypes.find(t); |