From: Lars Knoll Date: Wed, 26 Jun 2013 18:53:13 +0000 (+0200) Subject: Remove some unused code and forward declarations X-Git-Tag: upstream/5.2.1~669^2~108 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8cb3b016885a861fcd2af24e559e768eabecc3ae;p=platform%2Fupstream%2Fqtdeclarative.git Remove some unused code and forward declarations Change-Id: I2ab2818159c60b199cae4f7573ea47b01a178e7b Reviewed-by: Simon Hausmann --- diff --git a/src/qml/qml/qqmlabstractbinding_p.h b/src/qml/qml/qqmlabstractbinding_p.h index 8b93ea0..7ac10a6 100644 --- a/src/qml/qml/qqmlabstractbinding_p.h +++ b/src/qml/qml/qqmlabstractbinding_p.h @@ -149,7 +149,6 @@ private: friend class QQmlPropertyPrivate; friend class QQmlVME; friend class QtSharedPointer::ExternalRefCount; - friend class QV8QObjectWrapper; friend class QV4Bindings; typedef QSharedPointer SharedPointer; diff --git a/src/qml/qml/qqmlpropertycache.cpp b/src/qml/qml/qqmlpropertycache.cpp index 65406c9..d047de7 100644 --- a/src/qml/qml/qqmlpropertycache.cpp +++ b/src/qml/qml/qqmlpropertycache.cpp @@ -290,11 +290,8 @@ QQmlPropertyCache::~QQmlPropertyCache() void QQmlPropertyCache::destroy() { - Q_ASSERT(engine || constructor.isEmpty()); - if (constructor.isEmpty()) - delete this; - else - QQmlEnginePrivate::deleteInEngineThread(engine, this); + Q_ASSERT(engine); + delete this; } // This is inherited from QQmlCleanup, so it should only clear the things @@ -317,8 +314,6 @@ QQmlPropertyCache *QQmlPropertyCache::copy(int reserve) cache->_metaObject = _metaObject; cache->_defaultPropertyName = _defaultPropertyName; - // We specifically do *NOT* copy the constructor - return cache; } @@ -547,11 +542,6 @@ QQmlPropertyCache *QQmlPropertyCache::parent() const return _parent; } -void QQmlPropertyCache::setParent(QQmlPropertyCache *newParent) -{ - _parent = newParent; -} - // Returns the first C++ type's QMetaObject - that is, the first QMetaObject not created by // QML const QMetaObject *QQmlPropertyCache::firstCppMetaObject() const @@ -598,7 +588,6 @@ void QQmlPropertyCache::append(QQmlEngine *engine, const QMetaObject *metaObject QQmlPropertyData::Flag signalFlags) { Q_UNUSED(revision); - Q_ASSERT(constructor.isEmpty()); // We should not be appending to an in-use property cache _metaObject = metaObject; diff --git a/src/qml/qml/qqmlpropertycache_p.h b/src/qml/qml/qqmlpropertycache_p.h index 7bc7c46..b7a9055 100644 --- a/src/qml/qml/qqmlpropertycache_p.h +++ b/src/qml/qml/qqmlpropertycache_p.h @@ -68,7 +68,6 @@ QT_BEGIN_NAMESPACE class QV8Engine; class QMetaProperty; -class QV8QObjectWrapper; class QQmlEngine; class QQmlPropertyData; class QQmlAccessors; @@ -296,7 +295,6 @@ public: QString defaultPropertyName() const; QQmlPropertyData *defaultProperty() const; QQmlPropertyCache *parent() const; - void setParent(QQmlPropertyCache *newParent); inline QQmlPropertyData *overrideData(QQmlPropertyData *) const; inline bool isAllowedInRevision(QQmlPropertyData *) const; @@ -337,7 +335,6 @@ protected: private: friend class QQmlEnginePrivate; - friend class QV8QObjectWrapper; friend class QQmlCompiler; inline QQmlPropertyCache *copy(int reserve); @@ -389,7 +386,6 @@ private: IndexCache signalHandlerIndexCache; StringCache stringCache; AllowedRevisionCache allowedRevisionCache; - QV4::PersistentValue constructor; bool _hasPropertyOverrides : 1; bool _ownMetaObject : 1; diff --git a/src/qml/qml/qqmlvmemetaobject_p.h b/src/qml/qml/qqmlvmemetaobject_p.h index 3ee13d9..9824e0d 100644 --- a/src/qml/qml/qqmlvmemetaobject_p.h +++ b/src/qml/qml/qqmlvmemetaobject_p.h @@ -153,7 +153,6 @@ public: int m_index : 31; }; -class QV8QObjectWrapper; class QQmlVMEVariant; class QQmlRefCount; class QQmlVMEMetaObjectEndpoint; @@ -251,7 +250,6 @@ public: QQmlVMEVariantQObjectPtr *getQObjectGuardForProperty(int) const; friend class QV8GCCallback; - friend class QV8QObjectWrapper; }; QQmlVMEMetaObject *QQmlVMEMetaObject::get(QObject *obj) diff --git a/src/qml/qml/v8/qv8engine_p.h b/src/qml/qml/v8/qv8engine_p.h index 04eacfc..c1244d2 100644 --- a/src/qml/qml/v8/qv8engine_p.h +++ b/src/qml/qml/v8/qv8engine_p.h @@ -132,7 +132,6 @@ public: void setReturnValue(const QV4::Value &rv) { *retVal = rv; } QV8Engine *engine() const { return e; } private: - friend class QV8QObjectWrapper; friend struct QV4::QObjectMethod; QQmlV4Function(); QQmlV4Function(const QQmlV4Function &);