summaryrefslogtreecommitdiffstats
path: root/src/script/api
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-07-29 10:58:20 (GMT)
committerKent Hansen <khansen@trolltech.com>2009-07-29 10:59:12 (GMT)
commitad255eac6aaba9ac1689145bbf47376c354996aa (patch)
tree6094a1775227e290b3d0d62647e7162188b9823b /src/script/api
parent1ae869d6dfaf3f07d5cdb1fd951a711edd96eff7 (diff)
downloadQt-ad255eac6aaba9ac1689145bbf47376c354996aa.zip
Qt-ad255eac6aaba9ac1689145bbf47376c354996aa.tar.gz
Qt-ad255eac6aaba9ac1689145bbf47376c354996aa.tar.bz2
set calledAsConstructor to true when function is called as constructor
Diffstat (limited to 'src/script/api')
-rw-r--r--src/script/api/qscriptcontext.cpp5
-rw-r--r--src/script/api/qscriptcontext_p.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/src/script/api/qscriptcontext.cpp b/src/script/api/qscriptcontext.cpp
index f0f7b24..0efb037 100644
--- a/src/script/api/qscriptcontext.cpp
+++ b/src/script/api/qscriptcontext.cpp
@@ -189,6 +189,11 @@ const QScriptContextPrivate *QScriptContextPrivate::get(const QScriptContext *q)
return q->d_func();
}
+QScriptContextPrivate *QScriptContextPrivate::get(QScriptContext *q)
+{
+ return q->d_func();
+}
+
/*!
\internal
*/
diff --git a/src/script/api/qscriptcontext_p.h b/src/script/api/qscriptcontext_p.h
index 1aaf546..43efd06 100644
--- a/src/script/api/qscriptcontext_p.h
+++ b/src/script/api/qscriptcontext_p.h
@@ -81,6 +81,7 @@ public:
static QScriptContext *create(JSC::ExecState *frame,
QScriptEnginePrivate *engine);
static const QScriptContextPrivate *get(const QScriptContext *q);
+ static QScriptContextPrivate *get(QScriptContext *q);
JSC::ExecState *frame;
bool calledAsConstructor;