aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2011-08-11 09:15:38 +0200
committerQt by Nokia <qt-info@nokia.com>2011-08-11 10:22:16 +0200
commit038619bf2c5e7d2c18a6f463cd994d8b3831e61f (patch)
treeca7a0ed34b0a04056b487f64b6c9fa38344f24b5 /src
parentc595315fe45a2baf7a18262d76bb9eb1070d20b4 (diff)
Set IsDirect flag of property cache data if appropriate
The IsDirect flag was only set in QDeclarativePropertyCache::append(), but it should be set in create() as well. Change-Id: I43c980e5f7e01e44ade662c11c2daf7a9a44d299 Reviewed-on: http://codereview.qt.nokia.com/2844 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
Diffstat (limited to 'src')
-rw-r--r--src/declarative/qml/qdeclarativepropertycache.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/declarative/qml/qdeclarativepropertycache.cpp b/src/declarative/qml/qdeclarativepropertycache.cpp
index d2148ad874..0c595a9db5 100644
--- a/src/declarative/qml/qdeclarativepropertycache.cpp
+++ b/src/declarative/qml/qdeclarativepropertycache.cpp
@@ -247,6 +247,8 @@ QDeclarativePropertyCache::Data QDeclarativePropertyCache::create(const QMetaObj
QMetaProperty p = metaObject->property(idx);
if (p.isScriptable()) {
rv.load(metaObject->property(idx));
+ if (!isDynamicMetaObject(cmo))
+ rv.flags |= Data::IsDirect;
return rv;
} else {
while (cmo && cmo->propertyOffset() >= idx)
@@ -271,6 +273,8 @@ QDeclarativePropertyCache::Data QDeclarativePropertyCache::create(const QMetaObj
if (methodNameRef == property) {
rv.load(m);
+ if (!isDynamicMetaObject(m.enclosingMetaObject()))
+ rv.flags |= Data::IsDirect;
return rv;
}
}