aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlvmemetaobject_p.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@qt.io>2016-06-03 13:44:24 +0200
committerSimon Hausmann <simon.hausmann@qt.io>2016-06-03 13:24:14 +0000
commitbfa87b7bd8f8fb94889fd99ee413e69bc17f9e81 (patch)
tree8adfbd2e25c06480be7e25c5b62d1f8fe6bd84d7 /src/qml/qml/qqmlvmemetaobject_p.h
parent8ea3763a22d4ae114eee0063ef1c3ce31ac1b44d (diff)
Clean up property cache reference counting in QQmlVMEMetaObject
When the intercepting functionality of the VME meta-object was split into the QQmlInterceptorMetaObject the property cache was moved as a member but the manual refcounting remained in the QQmlVMEMetaObject constructor and destructor. That's fragile and potential future sub-classes of the interceptor would have to do the same refcounting. Instead let's just store a QQmlRefPointer in the right place. Similar logic applies to the QQmlDesignerMetaObject, which had a copy of the property cache for now aparent reason. Change-Id: I7f6d3917fc5ef1c4beb065525be10bb9c0fadcf3 Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlvmemetaobject_p.h')
-rw-r--r--src/qml/qml/qqmlvmemetaobject_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlvmemetaobject_p.h b/src/qml/qml/qqmlvmemetaobject_p.h
index 41f454eb62..5aa141d026 100644
--- a/src/qml/qml/qqmlvmemetaobject_p.h
+++ b/src/qml/qml/qqmlvmemetaobject_p.h
@@ -111,7 +111,7 @@ protected:
public:
QObject *object;
- QQmlPropertyCache *cache;
+ QQmlRefPointer<QQmlPropertyCache> cache;
QBiPointer<QDynamicMetaObjectData, const QMetaObject> parent;
QQmlPropertyValueInterceptor *interceptors;