diff options
Diffstat (limited to 'src/script/api/qscriptvalue_p.h')
-rw-r--r-- | src/script/api/qscriptvalue_p.h | 55 |
1 files changed, 27 insertions, 28 deletions
diff --git a/src/script/api/qscriptvalue_p.h b/src/script/api/qscriptvalue_p.h index 9456ace..a438178 100644 --- a/src/script/api/qscriptvalue_p.h +++ b/src/script/api/qscriptvalue_p.h @@ -59,12 +59,11 @@ QT_BEGIN_NAMESPACE #include "wtf/Platform.h" #include "JSValue.h" -#include "qscriptengine.h" class QString; -class QScriptValue; - +class QScriptEnginePrivate; +class QScriptValue; class QScriptValuePrivate { /** Helper class used only in QScriptValuePrivate. Supports atomatic invalidation of all script @@ -75,31 +74,31 @@ class QScriptValuePrivate class QScriptValueAutoRegister { QScriptValuePrivate *val; - QScriptEngine *ptr; - public: - QScriptValueAutoRegister(QScriptValuePrivate *value) : val(value), ptr(0) {}; - QScriptValueAutoRegister(QScriptValuePrivate *value, const QScriptEngine *engine); - ~QScriptValueAutoRegister(); - - QScriptValueAutoRegister& operator=(const QScriptEngine* pointer); - - operator QScriptEngine*() const - { - return ptr; - } - - operator bool() const - { - return ptr; - } - - QScriptEngine* operator->() - { - return ptr; - } - - private: - QScriptValueAutoRegister(QScriptValueAutoRegister &/*enigne*/){}; //block it + QScriptEnginePrivate *ptr; + public: + QScriptValueAutoRegister(QScriptValuePrivate *value) : val(value), ptr(0) {}; + QScriptValueAutoRegister(QScriptValuePrivate *value, const QScriptEnginePrivate *engine); + ~QScriptValueAutoRegister(); + + QScriptValueAutoRegister& operator=(const QScriptEnginePrivate* pointer); + + operator QScriptEnginePrivate*() const + { + return ptr; + } + + operator bool() const + { + return ptr; + } + + QScriptEnginePrivate* operator->() const + { + return ptr; + } + + private: + QScriptValueAutoRegister(QScriptValueAutoRegister &/*engine*/){}; //block it }; Q_DISABLE_COPY(QScriptValuePrivate); |