diff options
Diffstat (limited to 'src/script')
-rw-r--r-- | src/script/qscriptable.h | 2 | ||||
-rw-r--r-- | src/script/qscriptclass.h | 2 | ||||
-rw-r--r-- | src/script/qscriptclasspropertyiterator.h | 2 | ||||
-rw-r--r-- | src/script/qscriptcontext.h | 2 | ||||
-rw-r--r-- | src/script/qscriptcontextinfo.h | 2 | ||||
-rw-r--r-- | src/script/qscriptengine.h | 4 | ||||
-rw-r--r-- | src/script/qscriptengineagent.h | 2 | ||||
-rw-r--r-- | src/script/qscriptstring.cpp | 8 | ||||
-rw-r--r-- | src/script/qscriptstring.h | 6 | ||||
-rw-r--r-- | src/script/qscriptvalue.cpp | 8 | ||||
-rw-r--r-- | src/script/qscriptvalue.h | 6 | ||||
-rw-r--r-- | src/script/qscriptvalueiterator.h | 2 |
12 files changed, 17 insertions, 29 deletions
diff --git a/src/script/qscriptable.h b/src/script/qscriptable.h index 76a0496..11ecb6b 100644 --- a/src/script/qscriptable.h +++ b/src/script/qscriptable.h @@ -78,7 +78,7 @@ private: QScopedPointer<QScriptablePrivate> d_ptr; Q_DISABLE_COPY(QScriptable) - Q_DECLARE_PRIVATE(QScriptable) + Q_DECLARE_SCOPED_PRIVATE(QScriptable) }; #endif // QT_NO_QOBJECT diff --git a/src/script/qscriptclass.h b/src/script/qscriptclass.h index 7070470..e821cf7 100644 --- a/src/script/qscriptclass.h +++ b/src/script/qscriptclass.h @@ -107,7 +107,7 @@ protected: QScopedPointer<QScriptClassPrivate> d_ptr; private: - Q_DECLARE_PRIVATE(QScriptClass) + Q_DECLARE_SCOPED_PRIVATE(QScriptClass) Q_DISABLE_COPY(QScriptClass) }; diff --git a/src/script/qscriptclasspropertyiterator.h b/src/script/qscriptclasspropertyiterator.h index 1570410..ce6d3d4 100644 --- a/src/script/qscriptclasspropertyiterator.h +++ b/src/script/qscriptclasspropertyiterator.h @@ -84,7 +84,7 @@ protected: QScopedPointer<QScriptClassPropertyIteratorPrivate> d_ptr; private: - Q_DECLARE_PRIVATE(QScriptClassPropertyIterator) + Q_DECLARE_SCOPED_PRIVATE(QScriptClassPropertyIterator) Q_DISABLE_COPY(QScriptClassPropertyIterator) }; diff --git a/src/script/qscriptcontext.h b/src/script/qscriptcontext.h index 5a86cba..84d4192 100644 --- a/src/script/qscriptcontext.h +++ b/src/script/qscriptcontext.h @@ -114,7 +114,7 @@ private: QScopedPointer<QScriptContextPrivate> d_ptr; - Q_DECLARE_PRIVATE(QScriptContext) + Q_DECLARE_SCOPED_PRIVATE(QScriptContext) Q_DISABLE_COPY(QScriptContext) }; diff --git a/src/script/qscriptcontextinfo.h b/src/script/qscriptcontextinfo.h index 3540060..95e88e2 100644 --- a/src/script/qscriptcontextinfo.h +++ b/src/script/qscriptcontextinfo.h @@ -107,7 +107,7 @@ public: private: QScopedSharedPointer<QScriptContextInfoPrivate> d_ptr; - Q_DECLARE_PRIVATE(QScriptContextInfo) + Q_DECLARE_SCOPED_PRIVATE(QScriptContextInfo) }; typedef QList<QScriptContextInfo> QScriptContextInfoList; diff --git a/src/script/qscriptengine.h b/src/script/qscriptengine.h index 794c965..4f39c57 100644 --- a/src/script/qscriptengine.h +++ b/src/script/qscriptengine.h @@ -117,7 +117,7 @@ private: QScriptSyntaxCheckResult(QScriptSyntaxCheckResultPrivate *d); QScopedSharedPointer<QScriptSyntaxCheckResultPrivate> d_ptr; - Q_DECLARE_PRIVATE(QScriptSyntaxCheckResult) + Q_DECLARE_SCOPED_PRIVATE(QScriptSyntaxCheckResult) friend class QScriptEnginePrivate; }; @@ -291,7 +291,7 @@ protected: #endif private: - Q_DECLARE_PRIVATE(QScriptEngine) + Q_DECLARE_SCOPED_PRIVATE(QScriptEngine) Q_DISABLE_COPY(QScriptEngine) #ifndef QT_NO_QOBJECT Q_PRIVATE_SLOT(d_func(), void _q_objectDestroyed(QObject *)) diff --git a/src/script/qscriptengineagent.h b/src/script/qscriptengineagent.h index e71560c..10209df 100644 --- a/src/script/qscriptengineagent.h +++ b/src/script/qscriptengineagent.h @@ -100,7 +100,7 @@ protected: QScopedPointer<QScriptEngineAgentPrivate> d_ptr; private: - Q_DECLARE_PRIVATE(QScriptEngineAgent) + Q_DECLARE_SCOPED_PRIVATE(QScriptEngineAgent) Q_DISABLE_COPY(QScriptEngineAgent) }; diff --git a/src/script/qscriptstring.cpp b/src/script/qscriptstring.cpp index 137c6d0..945e532 100644 --- a/src/script/qscriptstring.cpp +++ b/src/script/qscriptstring.cpp @@ -55,7 +55,7 @@ QT_BEGIN_NAMESPACE /*! \internal */ -struct QScriptStringPrivatePointerHandler +struct QScriptStringPrivatePointerDeleter { static inline void cleanup(QScriptStringPrivate *d) { @@ -69,12 +69,6 @@ struct QScriptStringPrivatePointerHandler delete d; } } - - static inline void reset(QScriptStringPrivate *&d, QScriptStringPrivate *other) - { - cleanup(d); - d = other; - } }; /*! diff --git a/src/script/qscriptstring.h b/src/script/qscriptstring.h index 7256ee9..17cb687 100644 --- a/src/script/qscriptstring.h +++ b/src/script/qscriptstring.h @@ -56,7 +56,7 @@ QT_MODULE(Script) class QScriptEngine; class QScriptStringPrivate; -struct QScriptStringPrivatePointerHandler; +struct QScriptStringPrivatePointerDeleter; class Q_SCRIPT_EXPORT QScriptString { @@ -76,9 +76,9 @@ public: operator QString() const; private: - QScopedCustomPointer<QScriptStringPrivate, QScriptStringPrivatePointerHandler> d_ptr; + QCustomScopedPointer<QScriptStringPrivate, QScriptStringPrivatePointerDeleter> d_ptr; - Q_DECLARE_PRIVATE(QScriptString) + Q_DECLARE_SCOPED_PRIVATE(QScriptString) }; QT_END_NAMESPACE diff --git a/src/script/qscriptvalue.cpp b/src/script/qscriptvalue.cpp index d99e912..608fef3 100644 --- a/src/script/qscriptvalue.cpp +++ b/src/script/qscriptvalue.cpp @@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE /*! \internal */ -struct QScriptValuePrivatePointerHandler +struct QScriptValuePrivatePointerDeleter { static inline void cleanup(QScriptValuePrivate *d) { @@ -71,12 +71,6 @@ struct QScriptValuePrivatePointerHandler delete d; } } - - static inline void reset(QScriptValuePrivate *&d, QScriptValuePrivate *other) - { - cleanup(d); - d = other; - } }; /*! diff --git a/src/script/qscriptvalue.h b/src/script/qscriptvalue.h index 8125d01..5b10f9e 100644 --- a/src/script/qscriptvalue.h +++ b/src/script/qscriptvalue.h @@ -72,7 +72,7 @@ typedef QList<QScriptValue> QScriptValueList; typedef double qsreal; class QScriptValuePrivate; -struct QScriptValuePrivatePointerHandler; +struct QScriptValuePrivatePointerDeleter; class Q_SCRIPT_EXPORT QScriptValue { public: @@ -223,9 +223,9 @@ private: inline QScriptValue(QScriptEngine *, void *); private: - QScopedCustomPointer<QScriptValuePrivate, QScriptValuePrivatePointerHandler> d_ptr; + QCustomScopedPointer<QScriptValuePrivate, QScriptValuePrivatePointerDeleter> d_ptr; - Q_DECLARE_PRIVATE(QScriptValue) + Q_DECLARE_SCOPED_PRIVATE(QScriptValue) }; Q_DECLARE_OPERATORS_FOR_FLAGS(QScriptValue::ResolveFlags) diff --git a/src/script/qscriptvalueiterator.h b/src/script/qscriptvalueiterator.h index c8684ea..a25d12c 100644 --- a/src/script/qscriptvalueiterator.h +++ b/src/script/qscriptvalueiterator.h @@ -88,7 +88,7 @@ public: private: QScopedPointer<QScriptValueIteratorPrivate> d_ptr; - Q_DECLARE_PRIVATE(QScriptValueIterator) + Q_DECLARE_SCOPED_PRIVATE(QScriptValueIterator) Q_DISABLE_COPY(QScriptValueIterator) }; |