diff options
author | Lars Knoll <lars.knoll@theqtcompany.com> | 2014-11-01 23:04:20 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2014-11-08 16:39:07 +0100 |
commit | ec8f1f68d623ae68cc7d79e19067884532e3db6f (patch) | |
tree | ccf08fdf46e677931ba839228c444f24bcbb202e /src/qml/qml | |
parent | 9d1cd3098a066c7b6689d4776bfd3a25621a26fc (diff) |
Begin moving the data out of Managed objects
We need to move the Data objects out of the Managed
objects, to avoid lots of trouble because inner classes
can't be forward declared in C++.
Instead move them all into a Heap namespace.
Change-Id: I736af60702b68a1759f4643aa16d64108693dea2
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/qml')
-rw-r--r-- | src/qml/qml/qqmlcomponent.cpp | 4 | ||||
-rw-r--r-- | src/qml/qml/qqmlcontextwrapper.cpp | 4 | ||||
-rw-r--r-- | src/qml/qml/qqmlcontextwrapper_p.h | 4 | ||||
-rw-r--r-- | src/qml/qml/qqmllistwrapper.cpp | 2 | ||||
-rw-r--r-- | src/qml/qml/qqmlxmlhttprequest.cpp | 2 | ||||
-rw-r--r-- | src/qml/qml/v8/qqmlbuiltinfunctions.cpp | 2 | ||||
-rw-r--r-- | src/qml/qml/v8/qqmlbuiltinfunctions_p.h | 2 |
7 files changed, 10 insertions, 10 deletions
diff --git a/src/qml/qml/qqmlcomponent.cpp b/src/qml/qml/qqmlcomponent.cpp index 980fc99b92..0ba72c1641 100644 --- a/src/qml/qml/qqmlcomponent.cpp +++ b/src/qml/qml/qqmlcomponent.cpp @@ -1090,7 +1090,7 @@ struct QmlIncubatorObject : public QV4::Object static QV4::ReturnedValue method_forceCompletion(QV4::CallContext *ctx); static void destroy(Managed *that); - static void markObjects(QV4::HeapObject *that, QV4::ExecutionEngine *e); + static void markObjects(QV4::Heap::Base *that, QV4::ExecutionEngine *e); void statusChanged(QQmlIncubator::Status); void setInitialState(QObject *); @@ -1503,7 +1503,7 @@ void QmlIncubatorObject::destroy(Managed *that) static_cast<QmlIncubatorObject *>(that)->d()->~Data(); } -void QmlIncubatorObject::markObjects(QV4::HeapObject *that, QV4::ExecutionEngine *e) +void QmlIncubatorObject::markObjects(QV4::Heap::Base *that, QV4::ExecutionEngine *e) { QmlIncubatorObject::Data *o = static_cast<QmlIncubatorObject::Data *>(that); o->valuemap.mark(e); diff --git a/src/qml/qml/qqmlcontextwrapper.cpp b/src/qml/qml/qqmlcontextwrapper.cpp index df62f285e3..bbb757797e 100644 --- a/src/qml/qml/qqmlcontextwrapper.cpp +++ b/src/qml/qml/qqmlcontextwrapper.cpp @@ -347,7 +347,7 @@ void QmlContextWrapper::destroy(Managed *that) static_cast<QmlContextWrapper *>(that)->d()->~Data(); } -void QmlContextWrapper::markObjects(HeapObject *m, ExecutionEngine *engine) +void QmlContextWrapper::markObjects(Heap::Base *m, ExecutionEngine *engine) { QmlContextWrapper::Data *This = static_cast<QmlContextWrapper::Data *>(m); if (This->idObjectsWrapper) @@ -465,7 +465,7 @@ ReturnedValue QQmlIdObjectsArray::getIndexed(Managed *m, uint index, bool *hasPr return QObjectWrapper::wrap(This->engine(), context->idValues[index].data()); } -void QQmlIdObjectsArray::markObjects(HeapObject *that, ExecutionEngine *engine) +void QQmlIdObjectsArray::markObjects(Heap::Base *that, ExecutionEngine *engine) { QQmlIdObjectsArray::Data *This = static_cast<QQmlIdObjectsArray::Data *>(that); This->contextWrapper->mark(engine); diff --git a/src/qml/qml/qqmlcontextwrapper_p.h b/src/qml/qml/qqmlcontextwrapper_p.h index ae9e795a5c..5f2229fe51 100644 --- a/src/qml/qml/qqmlcontextwrapper_p.h +++ b/src/qml/qml/qqmlcontextwrapper_p.h @@ -93,7 +93,7 @@ struct Q_QML_EXPORT QmlContextWrapper : Object static ReturnedValue get(Managed *m, String *name, bool *hasProperty); static void put(Managed *m, String *name, const ValueRef value); static void destroy(Managed *that); - static void markObjects(HeapObject *m, ExecutionEngine *engine); + static void markObjects(Heap::Base *m, ExecutionEngine *engine); static void registerQmlDependencies(ExecutionEngine *context, const CompiledData::Function *compiledFunction); @@ -111,7 +111,7 @@ struct QQmlIdObjectsArray : public Object V4_OBJECT(Object) static ReturnedValue getIndexed(Managed *m, uint index, bool *hasProperty); - static void markObjects(HeapObject *that, ExecutionEngine *engine); + static void markObjects(Heap::Base *that, ExecutionEngine *engine); }; diff --git a/src/qml/qml/qqmllistwrapper.cpp b/src/qml/qml/qqmllistwrapper.cpp index b62689c454..50f1b55b9b 100644 --- a/src/qml/qml/qqmllistwrapper.cpp +++ b/src/qml/qml/qqmllistwrapper.cpp @@ -53,7 +53,7 @@ QmlListWrapper::Data::Data(QV8Engine *engine) QV4::Scope scope(QV8Engine::getV4(engine)); QV4::ScopedObject o(scope, this); - o->setArrayType(ArrayData::Custom); + o->setArrayType(Heap::ArrayData::Custom); } QmlListWrapper::Data::~Data() diff --git a/src/qml/qml/qqmlxmlhttprequest.cpp b/src/qml/qml/qqmlxmlhttprequest.cpp index 2acd40ae44..c8bf521767 100644 --- a/src/qml/qml/qqmlxmlhttprequest.cpp +++ b/src/qml/qml/qqmlxmlhttprequest.cpp @@ -1639,7 +1639,7 @@ struct QQmlXMLHttpRequestCtor : public FunctionObject Object *proto; }; V4_OBJECT(FunctionObject) - static void markObjects(HeapObject *that, ExecutionEngine *e) { + static void markObjects(Heap::Base *that, ExecutionEngine *e) { QQmlXMLHttpRequestCtor::Data *c = static_cast<QQmlXMLHttpRequestCtor::Data *>(that); if (c->proto) c->proto->mark(e); diff --git a/src/qml/qml/v8/qqmlbuiltinfunctions.cpp b/src/qml/qml/v8/qqmlbuiltinfunctions.cpp index 3a593d1c5b..4ab360eb9a 100644 --- a/src/qml/qml/v8/qqmlbuiltinfunctions.cpp +++ b/src/qml/qml/v8/qqmlbuiltinfunctions.cpp @@ -1187,7 +1187,7 @@ ReturnedValue QQmlBindingFunction::call(Managed *that, CallData *callData) return This->d()->originalFunction->call(callData); } -void QQmlBindingFunction::markObjects(HeapObject *that, ExecutionEngine *e) +void QQmlBindingFunction::markObjects(Heap::Base *that, ExecutionEngine *e) { QQmlBindingFunction::Data *This = static_cast<QQmlBindingFunction::Data *>(that); This->originalFunction->mark(e); diff --git a/src/qml/qml/v8/qqmlbuiltinfunctions_p.h b/src/qml/qml/v8/qqmlbuiltinfunctions_p.h index 7fe7d2b914..19b30bcc86 100644 --- a/src/qml/qml/v8/qqmlbuiltinfunctions_p.h +++ b/src/qml/qml/v8/qqmlbuiltinfunctions_p.h @@ -155,7 +155,7 @@ struct QQmlBindingFunction : public QV4::FunctionObject static ReturnedValue call(Managed *that, CallData *callData); - static void markObjects(HeapObject *that, ExecutionEngine *e); + static void markObjects(Heap::Base *that, ExecutionEngine *e); static void destroy(Managed *that) { static_cast<QQmlBindingFunction *>(that)->d()->~Data(); } |