aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlvmemetaobject.cpp
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.cpp
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.cpp')
-rw-r--r--src/qml/qml/qqmlvmemetaobject.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/qml/qml/qqmlvmemetaobject.cpp b/src/qml/qml/qqmlvmemetaobject.cpp
index 8697a291e2..6907b26cd8 100644
--- a/src/qml/qml/qqmlvmemetaobject.cpp
+++ b/src/qml/qml/qqmlvmemetaobject.cpp
@@ -319,8 +319,6 @@ QQmlVMEMetaObject::QQmlVMEMetaObject(QObject *obj,
ctxt(QQmlData::get(obj, true)->outerContext),
aliasEndpoints(0), compilationUnit(qmlCompilationUnit), compiledObject(0)
{
- cache->addref();
-
QQmlData::get(obj)->hasVMEMetaObject = true;
if (compilationUnit && qmlObjectId >= 0) {
@@ -345,8 +343,6 @@ QQmlVMEMetaObject::~QQmlVMEMetaObject()
delete [] aliasEndpoints;
qDeleteAll(varObjectGuards);
-
- cache->release();
}
QV4::MemberData *QQmlVMEMetaObject::propertyAndMethodStorageAsMemberData()