summaryrefslogtreecommitdiffstats
path: root/src/script
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2010-04-20 18:13:02 +0200
committerKent Hansen <kent.hansen@nokia.com>2010-04-21 10:34:36 +0200
commitbee994a655104e3ac9674c8ac25043f79e01c1e7 (patch)
treed02332cbccc8e7c1b6d1881aba4f01c4398868cc /src/script
parent6c69440513ba9227edc47b6914190434b07ff973 (diff)
QtScript: regression with instanceof operator for QMetaObject wrappers
Tell JavaScriptCore that QMetaObject wrappers can be used as the second operand to instanceof; this is done by setting the ImplementsHasInstance flag. We don't actually have to implement hasInstance() because the default implementation does the right thing. Task-number: QTBUG-8366 Reviewed-by: Olivier Goffart
Diffstat (limited to 'src/script')
-rw-r--r--src/script/bridge/qscriptqobject_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/bridge/qscriptqobject_p.h b/src/script/bridge/qscriptqobject_p.h
index 448fa9938a..1866dcbff2 100644
--- a/src/script/bridge/qscriptqobject_p.h
+++ b/src/script/bridge/qscriptqobject_p.h
@@ -304,7 +304,7 @@ public:
static WTF::PassRefPtr<JSC::Structure> createStructure(JSC::JSValue prototype)
{
- return JSC::Structure::create(prototype, JSC::TypeInfo(JSC::ObjectType));
+ return JSC::Structure::create(prototype, JSC::TypeInfo(JSC::ObjectType, JSC::ImplementsHasInstance));
}
protected: