[V8] Pass an Isolate to V8DOMConfiguration
authorharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Feb 2013 07:39:56 +0000 (07:39 +0000)
committerharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Feb 2013 07:39:56 +0000 (07:39 +0000)
https://bugs.webkit.org/show_bug.cgi?id=108900

Reviewed by Adam Barth.

No tests. No change in behavior.

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateHeader):
(GenerateImplementation):
(GenerateToV8Converters):
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore::ConfigureV8Float64ArrayTemplate):
(WebCore::V8Float64Array::createWrapper):
* bindings/scripts/test/V8/V8Float64Array.h:
(WebCore::V8Float64Array::installPerContextProperties):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::ConfigureV8TestActiveDOMObjectTemplate):
(WebCore::V8TestActiveDOMObject::createWrapper):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(WebCore::V8TestActiveDOMObject::installPerContextProperties):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore::ConfigureV8TestCustomNamedGetterTemplate):
(WebCore::V8TestCustomNamedGetter::createWrapper):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(WebCore::V8TestCustomNamedGetter::installPerContextProperties):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore::ConfigureV8TestEventConstructorTemplate):
(WebCore::V8TestEventConstructor::createWrapper):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(WebCore::V8TestEventConstructor::installPerContextProperties):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore::ConfigureV8TestEventTargetTemplate):
(WebCore::V8TestEventTarget::createWrapper):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(WebCore::V8TestEventTarget::installPerContextProperties):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore::ConfigureV8TestExceptionTemplate):
(WebCore::V8TestException::createWrapper):
* bindings/scripts/test/V8/V8TestException.h:
(WebCore::V8TestException::installPerContextProperties):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore::ConfigureV8TestInterfaceTemplate):
(WebCore::V8TestInterface::createWrapper):
* bindings/scripts/test/V8/V8TestInterface.h:
(WebCore::V8TestInterface::installPerContextProperties):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
(WebCore::V8TestMediaQueryListListener::createWrapper):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(WebCore::V8TestMediaQueryListListener::installPerContextProperties):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::ConfigureV8TestNamedConstructorTemplate):
(WebCore::V8TestNamedConstructor::createWrapper):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(WebCore::V8TestNamedConstructor::installPerContextProperties):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::ConfigureV8TestNodeTemplate):
(WebCore::V8TestNode::createWrapper):
* bindings/scripts/test/V8/V8TestNode.h:
(WebCore::V8TestNode::installPerContextProperties):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::installPerContextProperties):
(WebCore::V8TestObj::createWrapper):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
(WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
(WebCore::V8TestOverloadedConstructors::createWrapper):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
(WebCore::V8TestOverloadedConstructors::installPerContextProperties):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
(WebCore::V8TestSerializedScriptValueInterface::createWrapper):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(WebCore::V8TestSerializedScriptValueInterface::installPerContextProperties):
* bindings/v8/V8DOMConfiguration.cpp:
(WebCore::V8DOMConfiguration::batchConfigureAttributes):
(WebCore::V8DOMConfiguration::batchConfigureConstants):
(WebCore::V8DOMConfiguration::batchConfigureCallbacks):
(WebCore::V8DOMConfiguration::configureTemplate):
* bindings/v8/V8DOMConfiguration.h:
(V8DOMConfiguration):
(WebCore::V8DOMConfiguration::configureAttribute):
* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::installDOMWindow):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@141862 268f45cc-cd09-0410-ab3c-d52691b4dbfc

31 files changed:
Source/WebCore/ChangeLog
Source/WebCore/bindings/scripts/CodeGeneratorV8.pm
Source/WebCore/bindings/scripts/test/V8/V8Float64Array.cpp
Source/WebCore/bindings/scripts/test/V8/V8Float64Array.h
Source/WebCore/bindings/scripts/test/V8/V8TestActiveDOMObject.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestActiveDOMObject.h
Source/WebCore/bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestCustomNamedGetter.h
Source/WebCore/bindings/scripts/test/V8/V8TestEventConstructor.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestEventConstructor.h
Source/WebCore/bindings/scripts/test/V8/V8TestEventTarget.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestEventTarget.h
Source/WebCore/bindings/scripts/test/V8/V8TestException.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestException.h
Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestInterface.h
Source/WebCore/bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestMediaQueryListListener.h
Source/WebCore/bindings/scripts/test/V8/V8TestNamedConstructor.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestNamedConstructor.h
Source/WebCore/bindings/scripts/test/V8/V8TestNode.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestNode.h
Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestObj.h
Source/WebCore/bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestOverloadedConstructors.h
Source/WebCore/bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp
Source/WebCore/bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h
Source/WebCore/bindings/v8/V8DOMConfiguration.cpp
Source/WebCore/bindings/v8/V8DOMConfiguration.h
Source/WebCore/bindings/v8/V8DOMWindowShell.cpp

index 1ef34b63886f9bbb1d4650bb1e46972189223cbf..24e57ef8853ecec324a183cbc252f801174f6294 100644 (file)
@@ -1,3 +1,93 @@
+2013-02-04  Kentaro Hara  <haraken@chromium.org>
+
+        [V8] Pass an Isolate to V8DOMConfiguration
+        https://bugs.webkit.org/show_bug.cgi?id=108900
+
+        Reviewed by Adam Barth.
+
+        No tests. No change in behavior.
+
+        * bindings/scripts/CodeGeneratorV8.pm:
+        (GenerateHeader):
+        (GenerateImplementation):
+        (GenerateToV8Converters):
+        * bindings/scripts/test/V8/V8Float64Array.cpp:
+        (WebCore::ConfigureV8Float64ArrayTemplate):
+        (WebCore::V8Float64Array::createWrapper):
+        * bindings/scripts/test/V8/V8Float64Array.h:
+        (WebCore::V8Float64Array::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
+        (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
+        (WebCore::V8TestActiveDOMObject::createWrapper):
+        * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
+        (WebCore::V8TestActiveDOMObject::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
+        (WebCore::ConfigureV8TestCustomNamedGetterTemplate):
+        (WebCore::V8TestCustomNamedGetter::createWrapper):
+        * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
+        (WebCore::V8TestCustomNamedGetter::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
+        (WebCore::ConfigureV8TestEventConstructorTemplate):
+        (WebCore::V8TestEventConstructor::createWrapper):
+        * bindings/scripts/test/V8/V8TestEventConstructor.h:
+        (WebCore::V8TestEventConstructor::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestEventTarget.cpp:
+        (WebCore::ConfigureV8TestEventTargetTemplate):
+        (WebCore::V8TestEventTarget::createWrapper):
+        * bindings/scripts/test/V8/V8TestEventTarget.h:
+        (WebCore::V8TestEventTarget::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestException.cpp:
+        (WebCore::ConfigureV8TestExceptionTemplate):
+        (WebCore::V8TestException::createWrapper):
+        * bindings/scripts/test/V8/V8TestException.h:
+        (WebCore::V8TestException::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestInterface.cpp:
+        (WebCore::ConfigureV8TestInterfaceTemplate):
+        (WebCore::V8TestInterface::createWrapper):
+        * bindings/scripts/test/V8/V8TestInterface.h:
+        (WebCore::V8TestInterface::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
+        (WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
+        (WebCore::V8TestMediaQueryListListener::createWrapper):
+        * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
+        (WebCore::V8TestMediaQueryListListener::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
+        (WebCore::ConfigureV8TestNamedConstructorTemplate):
+        (WebCore::V8TestNamedConstructor::createWrapper):
+        * bindings/scripts/test/V8/V8TestNamedConstructor.h:
+        (WebCore::V8TestNamedConstructor::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestNode.cpp:
+        (WebCore::ConfigureV8TestNodeTemplate):
+        (WebCore::V8TestNode::createWrapper):
+        * bindings/scripts/test/V8/V8TestNode.h:
+        (WebCore::V8TestNode::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestObj.cpp:
+        (WebCore::ConfigureV8TestObjTemplate):
+        (WebCore::V8TestObj::installPerContextProperties):
+        (WebCore::V8TestObj::createWrapper):
+        * bindings/scripts/test/V8/V8TestObj.h:
+        (V8TestObj):
+        * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
+        (WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
+        (WebCore::V8TestOverloadedConstructors::createWrapper):
+        * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
+        (WebCore::V8TestOverloadedConstructors::installPerContextProperties):
+        * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
+        (WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
+        (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
+        * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
+        (WebCore::V8TestSerializedScriptValueInterface::installPerContextProperties):
+        * bindings/v8/V8DOMConfiguration.cpp:
+        (WebCore::V8DOMConfiguration::batchConfigureAttributes):
+        (WebCore::V8DOMConfiguration::batchConfigureConstants):
+        (WebCore::V8DOMConfiguration::batchConfigureCallbacks):
+        (WebCore::V8DOMConfiguration::configureTemplate):
+        * bindings/v8/V8DOMConfiguration.h:
+        (V8DOMConfiguration):
+        (WebCore::V8DOMConfiguration::configureAttribute):
+        * bindings/v8/V8DOMWindowShell.cpp:
+        (WebCore::V8DOMWindowShell::installDOMWindow):
+
 2013-02-04  Kentaro Hara  <haraken@chromium.org>
 
         [V8] Clean up CodeGeneratorV8.pm by introducing HasCustom{Getter,Setter,Method}
index 4640944f60e0f36a5506ef9010d41b926bab5faa..4a6c965ce626acb4994a3beba5e2f5bc271b8084 100644 (file)
@@ -454,11 +454,11 @@ END
 
     if (@enabledPerContextAttributes) {
         push(@headerContent, <<END);
-    static void installPerContextProperties(v8::Handle<v8::Object>, ${nativeType}*);
+    static void installPerContextProperties(v8::Handle<v8::Object>, ${nativeType}*, v8::Isolate*);
 END
     } else {
         push(@headerContent, <<END);
-    static void installPerContextProperties(v8::Handle<v8::Object>, ${nativeType}*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, ${nativeType}*, v8::Isolate*) { }
 END
     }
 
@@ -2929,7 +2929,7 @@ END
         push(@implContent, <<END);
 static v8::Persistent<v8::ObjectTemplate> ConfigureShadowObjectTemplate(v8::Persistent<v8::ObjectTemplate> templ, v8::Isolate* isolate)
 {
-    V8DOMConfiguration::batchConfigureAttributes(templ, v8::Handle<v8::ObjectTemplate>(), shadowAttrs, WTF_ARRAY_LENGTH(shadowAttrs));
+    V8DOMConfiguration::batchConfigureAttributes(templ, v8::Handle<v8::ObjectTemplate>(), shadowAttrs, WTF_ARRAY_LENGTH(shadowAttrs), isolate);
 
     // Install a security handler with V8.
     templ->SetAccessCheckCallbacks(V8DOMWindow::namedSecurityCheck, V8DOMWindow::indexedSecurityCheck, v8::External::New(&V8DOMWindow::info));
@@ -2955,7 +2955,7 @@ END
         my $enable_function = GetRuntimeEnableFunctionName($interface);
         push(@implContent, <<END);
     if (!${enable_function}())
-        defaultSignature = V8DOMConfiguration::configureTemplate(desc, \"\", $parentClassTemplate, ${v8InterfaceName}::internalFieldCount, 0, 0, 0, 0);
+        defaultSignature = V8DOMConfiguration::configureTemplate(desc, \"\", $parentClassTemplate, ${v8InterfaceName}::internalFieldCount, 0, 0, 0, 0, isolate);
     else
 END
     }
@@ -2975,14 +2975,14 @@ END
 
     if ($has_callbacks) {
         push(@implContent, <<END);
-        ${v8InterfaceName}Callbacks, WTF_ARRAY_LENGTH(${v8InterfaceName}Callbacks));
+        ${v8InterfaceName}Callbacks, WTF_ARRAY_LENGTH(${v8InterfaceName}Callbacks), isolate);
 END
     } else {
         push(@implContent, <<END);
-        0, 0);
+        0, 0, isolate);
 END
     }
-    
+
     AddToImplIncludes("wtf/UnusedParam.h");
     push(@implContent, <<END);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
@@ -3015,7 +3015,7 @@ END
         push(@implContent, "        static const V8DOMConfiguration::BatchedAttribute attrData =\\\n");
         GenerateSingleBatchedAttribute($interfaceName, $runtime_attr, ";", "    ");
         push(@implContent, <<END);
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
     }
 END
         push(@implContent, "\n#endif // ${conditionalString}\n") if $conditionalString;
@@ -3031,7 +3031,7 @@ END
         push(@implContent, "    if (${enable_function}()) {\n");
         push(@implContent, <<END);
         static const V8DOMConfiguration::BatchedConstant constData = {"${name}", static_cast<signed int>(${value})};
-        V8DOMConfiguration::batchConfigureConstants(desc, proto, &constData, 1);
+        V8DOMConfiguration::batchConfigureConstants(desc, proto, &constData, 1, isolate);
 END
         push(@implContent, "    }\n");
         push(@implContent, "\n#endif // ${conditionalString}\n") if $conditionalString;
@@ -3058,7 +3058,7 @@ END
 
     if ($has_constants) {
         push(@implContent, <<END);
-    V8DOMConfiguration::batchConfigureConstants(desc, proto, ${v8InterfaceName}Consts, WTF_ARRAY_LENGTH(${v8InterfaceName}Consts));
+    V8DOMConfiguration::batchConfigureConstants(desc, proto, ${v8InterfaceName}Consts, WTF_ARRAY_LENGTH(${v8InterfaceName}Consts), isolate);
 END
     }
 
@@ -3140,7 +3140,7 @@ END
 
     if (@enabledPerContextAttributes) {
         push(@implContent, <<END);
-void ${v8InterfaceName}::installPerContextProperties(v8::Handle<v8::Object> instance, ${nativeType}* impl)
+void ${v8InterfaceName}::installPerContextProperties(v8::Handle<v8::Object> instance, ${nativeType}* impl, v8::Isolate* isolate)
 {
     v8::Local<v8::Object> proto = v8::Local<v8::Object>::Cast(instance->GetPrototype());
     // When building QtWebkit with V8 this variable is unused when none of the features are enabled.
@@ -3156,7 +3156,7 @@ END
             push(@implContent, "        static const V8DOMConfiguration::BatchedAttribute attrData =\\\n");
             GenerateSingleBatchedAttribute($interfaceName, $runtimeAttr, ";", "    ");
             push(@implContent, <<END);
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
 END
             push(@implContent, "    }\n");
             push(@implContent, "#endif // ${conditionalString}\n") if $conditionalString;
@@ -3543,7 +3543,7 @@ END
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 79d973417c87c2967aa12e71eeba1f5a491b9d2b..02d44830221324a5ed28bedb9eb5c11f0d2868d5 100644 (file)
@@ -112,7 +112,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8Float64ArrayTemplate(v8::
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "Float64Array", V8ArrayBufferView::GetTemplate(isolate), V8Float64Array::internalFieldCount,
         0, 0,
-        V8Float64ArrayCallbacks, WTF_ARRAY_LENGTH(V8Float64ArrayCallbacks));
+        V8Float64ArrayCallbacks, WTF_ARRAY_LENGTH(V8Float64ArrayCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8Float64Array::constructorCallback);
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
@@ -185,7 +185,7 @@ v8::Handle<v8::Object> V8Float64Array::createWrapper(PassRefPtr<Float64Array> im
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 0dd9efc8b0b8dd62d6faaf09074a3f34764884ff..fb8801d0e49dc43aee2498bb61da0acef9840bc7 100644 (file)
@@ -46,7 +46,7 @@ public:
     static WrapperTypeInfo info;
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, Float64Array*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, Float64Array*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(Float64Array*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index f1ef3bdf71eab194a8492ff3b54454190d6a69d9..6e3ee6dec2918e94745f6ab71129eb1f0ad4c1b8 100644 (file)
@@ -138,7 +138,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestActiveDOMObjectTempla
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestActiveDOMObject", v8::Persistent<v8::FunctionTemplate>(), V8TestActiveDOMObject::internalFieldCount,
         V8TestActiveDOMObjectAttrs, WTF_ARRAY_LENGTH(V8TestActiveDOMObjectAttrs),
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
     v8::Local<v8::ObjectTemplate> proto = desc->PrototypeTemplate();
@@ -212,7 +212,7 @@ v8::Handle<v8::Object> V8TestActiveDOMObject::createWrapper(PassRefPtr<TestActiv
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 72efe0cef7cc70c621cb36c6db07968a03d238e9..c006f2f62ce8fbcee2f9f694fc075eb74e091d04 100644 (file)
@@ -46,7 +46,7 @@ public:
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
     static bool namedSecurityCheck(v8::Local<v8::Object> host, v8::Local<v8::Value> key, v8::AccessType, v8::Local<v8::Value> data);
     static bool indexedSecurityCheck(v8::Local<v8::Object> host, uint32_t index, v8::AccessType, v8::Local<v8::Value> data);
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestActiveDOMObject*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestActiveDOMObject*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestActiveDOMObject*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 414289830a4ff30e2c159bdc12aef01d9082dbfc..d092740c0e6eada17f0875871205b4558db91195 100644 (file)
@@ -84,7 +84,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestCustomNamedGetterTemp
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestCustomNamedGetter", v8::Persistent<v8::FunctionTemplate>(), V8TestCustomNamedGetter::internalFieldCount,
         0, 0,
-        V8TestCustomNamedGetterCallbacks, WTF_ARRAY_LENGTH(V8TestCustomNamedGetterCallbacks));
+        V8TestCustomNamedGetterCallbacks, WTF_ARRAY_LENGTH(V8TestCustomNamedGetterCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
     v8::Local<v8::ObjectTemplate> proto = desc->PrototypeTemplate();
@@ -150,7 +150,7 @@ v8::Handle<v8::Object> V8TestCustomNamedGetter::createWrapper(PassRefPtr<TestCus
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index f4b540224f72d7d0215432a34d9e959acdc0cae4..34b58d8da84f60e9c630d13eeaf21a9808b5689b 100644 (file)
@@ -45,7 +45,7 @@ public:
     static WrapperTypeInfo info;
     static v8::Handle<v8::Value> namedPropertyGetter(v8::Local<v8::String>, const v8::AccessorInfo&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestCustomNamedGetter*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestCustomNamedGetter*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestCustomNamedGetter*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 7031f5c7e9bf5e72db97e45f3ce650ad18412bb8..9f6aa3453ac6126b3e3f2dea2b2fb121e750e1cc 100644 (file)
@@ -120,7 +120,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestEventConstructorTempl
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestEventConstructor", v8::Persistent<v8::FunctionTemplate>(), V8TestEventConstructor::internalFieldCount,
         V8TestEventConstructorAttrs, WTF_ARRAY_LENGTH(V8TestEventConstructorAttrs),
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8TestEventConstructor::constructorCallback);
     
@@ -182,7 +182,7 @@ v8::Handle<v8::Object> V8TestEventConstructor::createWrapper(PassRefPtr<TestEven
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 2efa6a59f6e5c1c903fffd5f6883a059da9071b9..4c7afa09a95177769f0d9ecda3adeb82ec21f644 100644 (file)
@@ -46,7 +46,7 @@ public:
     static WrapperTypeInfo info;
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestEventConstructor*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestEventConstructor*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestEventConstructor*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 768b1a72859486fa0d18cfe115302d0f1307e7c8..b6e670f615d4d69b0f1e49f572d55b0d2bf962fd 100644 (file)
@@ -137,7 +137,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestEventTargetTemplate(v
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestEventTarget", v8::Persistent<v8::FunctionTemplate>(), V8TestEventTarget::internalFieldCount,
         0, 0,
-        V8TestEventTargetCallbacks, WTF_ARRAY_LENGTH(V8TestEventTargetCallbacks));
+        V8TestEventTargetCallbacks, WTF_ARRAY_LENGTH(V8TestEventTargetCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
     v8::Local<v8::ObjectTemplate> proto = desc->PrototypeTemplate();
@@ -216,7 +216,7 @@ v8::Handle<v8::Object> V8TestEventTarget::createWrapper(PassRefPtr<TestEventTarg
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 4bc3ed998b71661bfea93e6b2830f9f69aa30234..05ad032f421533d9cd4f8cadee14b15daddf45f6 100644 (file)
@@ -48,7 +48,7 @@ public:
     static v8::Handle<v8::Value> namedPropertyGetter(v8::Local<v8::String>, const v8::AccessorInfo&);
     static const int eventListenerCacheIndex = v8DefaultWrapperInternalFieldCount + 0;
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 1;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestEventTarget*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestEventTarget*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestEventTarget*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index f160f6c7dafc0a38909164657d6f01fc78745229..26d64d7fff8a423125c8bac1395d9ca7759dddf3 100644 (file)
@@ -80,7 +80,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestExceptionTemplate(v8:
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestException", v8::Persistent<v8::FunctionTemplate>(), V8TestException::internalFieldCount,
         V8TestExceptionAttrs, WTF_ARRAY_LENGTH(V8TestExceptionAttrs),
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     
 
@@ -141,7 +141,7 @@ v8::Handle<v8::Object> V8TestException::createWrapper(PassRefPtr<TestException>
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 9ff2a426c2eb2fc3648b5e4644b24a3463a5239f..37fe1db261cb2980dcda825a2caa84da7c7f38e1 100644 (file)
@@ -44,7 +44,7 @@ public:
     static void derefObject(void*);
     static WrapperTypeInfo info;
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestException*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestException*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestException*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 5ba2131accdec8107cc54fd2af7127276ccfd842..f780f137601c734de0b77baa4dbf99ff90872c55 100644 (file)
@@ -286,7 +286,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestInterfaceTemplate(v8:
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestInterface", v8::Persistent<v8::FunctionTemplate>(), V8TestInterface::internalFieldCount,
         V8TestInterfaceAttrs, WTF_ARRAY_LENGTH(V8TestInterfaceAttrs),
-        V8TestInterfaceCallbacks, WTF_ARRAY_LENGTH(V8TestInterfaceCallbacks));
+        V8TestInterfaceCallbacks, WTF_ARRAY_LENGTH(V8TestInterfaceCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
 #if ENABLE(TEST_INTERFACE)
     desc->SetCallHandler(V8TestInterface::constructorCallback);
@@ -307,7 +307,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestInterfaceTemplate(v8:
 #if ENABLE(Condition11) || ENABLE(Condition12)
     desc->Set(v8::String::NewSymbol("supplementalMethod4"), v8::FunctionTemplate::New(TestInterfaceV8Internal::supplementalMethod4Callback, v8Undefined(), v8::Local<v8::Signature>()));
 #endif // ENABLE(Condition11) || ENABLE(Condition12)
-    V8DOMConfiguration::batchConfigureConstants(desc, proto, V8TestInterfaceConsts, WTF_ARRAY_LENGTH(V8TestInterfaceConsts));
+    V8DOMConfiguration::batchConfigureConstants(desc, proto, V8TestInterfaceConsts, WTF_ARRAY_LENGTH(V8TestInterfaceConsts), isolate);
 
     // Custom toString template
     desc->Set(v8::String::NewSymbol("toString"), V8PerIsolateData::current()->toStringTemplate());
@@ -371,7 +371,7 @@ v8::Handle<v8::Object> V8TestInterface::createWrapper(PassRefPtr<TestInterface>
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index a1da12786832146850570ed4b3bcdc315af0e854..8752422128b0298e61d9c4b3f6b85228b5b40034 100644 (file)
@@ -49,7 +49,7 @@ public:
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static v8::Handle<v8::Value> namedPropertySetter(v8::Local<v8::String>, v8::Local<v8::Value>, const v8::AccessorInfo&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestInterface*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestInterface*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestInterface*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 71711634e986b185a35b8ae6a6ffe4c6451e3d9d..905d4f782cc4639fbd92cf99c9dad078d4f07b86 100644 (file)
@@ -85,7 +85,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestMediaQueryListListene
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestMediaQueryListListener", v8::Persistent<v8::FunctionTemplate>(), V8TestMediaQueryListListener::internalFieldCount,
         0, 0,
-        V8TestMediaQueryListListenerCallbacks, WTF_ARRAY_LENGTH(V8TestMediaQueryListListenerCallbacks));
+        V8TestMediaQueryListListenerCallbacks, WTF_ARRAY_LENGTH(V8TestMediaQueryListListenerCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
     v8::Local<v8::ObjectTemplate> proto = desc->PrototypeTemplate();
@@ -150,7 +150,7 @@ v8::Handle<v8::Object> V8TestMediaQueryListListener::createWrapper(PassRefPtr<Te
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 67a1bc368033dded940b5905140f803ea23eaaa2..172251f4d40e955fe404c3407cb7df6f04241bd1 100644 (file)
@@ -44,7 +44,7 @@ public:
     static void derefObject(void*);
     static WrapperTypeInfo info;
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestMediaQueryListListener*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestMediaQueryListListener*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestMediaQueryListListener*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 6e3e25fbf0651be5ca2aed8674b1ec4300ff0798..1550c0d1c96f08a15fdea21410e438e00f1362eb 100644 (file)
@@ -125,7 +125,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestNamedConstructorTempl
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestNamedConstructor", v8::Persistent<v8::FunctionTemplate>(), V8TestNamedConstructor::internalFieldCount,
         0, 0,
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     
 
@@ -191,7 +191,7 @@ v8::Handle<v8::Object> V8TestNamedConstructor::createWrapper(PassRefPtr<TestName
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 9284aa9e745d69b3ab151150188f597ece5517c4..79542fcf0b4bf48b3cc90d640e1716ddda9fba92 100644 (file)
@@ -51,7 +51,7 @@ public:
     static WrapperTypeInfo info;
     static ActiveDOMObject* toActiveDOMObject(v8::Handle<v8::Object>);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestNamedConstructor*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestNamedConstructor*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestNamedConstructor*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 971d3debc1f61c2b4ec074894c128a7856e5e53a..c3ad121ef14f6c3aa24ef82f026052ce5474f550 100644 (file)
@@ -86,7 +86,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestNodeTemplate(v8::Pers
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestNode", V8Node::GetTemplate(isolate), V8TestNode::internalFieldCount,
         0, 0,
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8TestNode::constructorCallback);
     
@@ -154,7 +154,7 @@ v8::Handle<v8::Object> V8TestNode::createWrapper(PassRefPtr<TestNode> impl, v8::
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 20573be5bb3c01e1f1912b97b670849be693d57b..d03204516c06968c68d3232a52b2be24f756c51a 100644 (file)
@@ -46,7 +46,7 @@ public:
     static EventTarget* toEventTarget(v8::Handle<v8::Object>);
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestNode*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestNode*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestNode*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index d26fc36f2228d8e934535151404785a92f2aa553..e89b1ac2b679f2f3599236deca338e4e30f25315 100644 (file)
@@ -2101,7 +2101,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestObjTemplate(v8::Persi
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestObject", v8::Persistent<v8::FunctionTemplate>(), V8TestObj::internalFieldCount,
         V8TestObjAttrs, WTF_ARRAY_LENGTH(V8TestObjAttrs),
-        V8TestObjCallbacks, WTF_ARRAY_LENGTH(V8TestObjCallbacks));
+        V8TestObjCallbacks, WTF_ARRAY_LENGTH(V8TestObjCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8TestObj::constructorCallback);
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
@@ -2113,13 +2113,13 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestObjTemplate(v8::Persi
         static const V8DOMConfiguration::BatchedAttribute attrData =\
         // Attribute 'enabledAtRuntimeAttr1' (Type: 'attribute' ExtAttr: 'V8EnabledAtRuntime')
         {"enabledAtRuntimeAttr1", TestObjV8Internal::enabledAtRuntimeAttr1AttrGetter, TestObjV8Internal::enabledAtRuntimeAttr1AttrSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */};
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
     }
     if (RuntimeEnabledFeatures::featureNameEnabled()) {
         static const V8DOMConfiguration::BatchedAttribute attrData =\
         // Attribute 'enabledAtRuntimeAttr2' (Type: 'attribute' ExtAttr: 'V8EnabledAtRuntime')
         {"enabledAtRuntimeAttr2", TestObjV8Internal::enabledAtRuntimeAttr2AttrGetter, TestObjV8Internal::enabledAtRuntimeAttr2AttrSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */};
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
     }
 
     // Custom Signature 'voidMethodWithArgs'
@@ -2203,7 +2203,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestObjTemplate(v8::Persi
     v8::Handle<v8::FunctionTemplate> variadicNodeMethodArgv[variadicNodeMethodArgc] = { V8Node::GetRawTemplate(isolate), V8Node::GetRawTemplate(isolate) };
     v8::Handle<v8::Signature> variadicNodeMethodSignature = v8::Signature::New(desc, variadicNodeMethodArgc, variadicNodeMethodArgv);
     proto->Set(v8::String::NewSymbol("variadicNodeMethod"), v8::FunctionTemplate::New(TestObjV8Internal::variadicNodeMethodCallback, v8Undefined(), variadicNodeMethodSignature));
-    V8DOMConfiguration::batchConfigureConstants(desc, proto, V8TestObjConsts, WTF_ARRAY_LENGTH(V8TestObjConsts));
+    V8DOMConfiguration::batchConfigureConstants(desc, proto, V8TestObjConsts, WTF_ARRAY_LENGTH(V8TestObjConsts), isolate);
 
     // Custom toString template
     desc->Set(v8::String::NewSymbol("toString"), V8PerIsolateData::current()->toStringTemplate());
@@ -2248,7 +2248,7 @@ bool V8TestObj::HasInstance(v8::Handle<v8::Value> value, v8::Isolate* isolate)
     return GetRawTemplate(isolate)->HasInstance(value);
 }
 
-void V8TestObj::installPerContextProperties(v8::Handle<v8::Object> instance, TestObj* impl)
+void V8TestObj::installPerContextProperties(v8::Handle<v8::Object> instance, TestObj* impl, v8::Isolate* isolate)
 {
     v8::Local<v8::Object> proto = v8::Local<v8::Object>::Cast(instance->GetPrototype());
     // When building QtWebkit with V8 this variable is unused when none of the features are enabled.
@@ -2257,13 +2257,13 @@ void V8TestObj::installPerContextProperties(v8::Handle<v8::Object> instance, Tes
         static const V8DOMConfiguration::BatchedAttribute attrData =\
         // Attribute 'enabledPerContextAttr1' (Type: 'attribute' ExtAttr: 'V8EnabledPerContext')
         {"enabledPerContextAttr1", TestObjV8Internal::enabledPerContextAttr1AttrGetter, TestObjV8Internal::enabledPerContextAttr1AttrSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */};
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
     }
     if (ContextFeatures::featureNameEnabled(impl->document())) {
         static const V8DOMConfiguration::BatchedAttribute attrData =\
         // Attribute 'enabledPerContextAttr2' (Type: 'attribute' ExtAttr: 'V8EnabledPerContext')
         {"enabledPerContextAttr2", TestObjV8Internal::enabledPerContextAttr2AttrGetter, TestObjV8Internal::enabledPerContextAttr2AttrSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */};
-        V8DOMConfiguration::configureAttribute(instance, proto, attrData);
+        V8DOMConfiguration::configureAttribute(instance, proto, attrData, isolate);
     }
 }
 
@@ -2296,7 +2296,7 @@ v8::Handle<v8::Object> V8TestObj::createWrapper(PassRefPtr<TestObj> impl, v8::Ha
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 0feb9f10b6567d82d419934867218c40633ca64b..057d49190e5d0e9b537d71f612aba73b3a9ed273 100644 (file)
@@ -50,7 +50,7 @@ public:
     static v8::Handle<v8::Value> customAttrAccessorGetter(v8::Local<v8::String> name, const v8::AccessorInfo&);
     static void customAttrAccessorSetter(v8::Local<v8::String> name, v8::Local<v8::Value>, const v8::AccessorInfo&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestObj*);
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestObj*, v8::Isolate*);
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>);
 private:
     friend v8::Handle<v8::Object> wrap(TestObj*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 974cc9782c6388ab1ab20786cc28d4f376375a27..e25f00cef1475aad1d97f2bfba55799f00665a1a 100644 (file)
@@ -143,7 +143,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestOverloadedConstructor
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestOverloadedConstructors", v8::Persistent<v8::FunctionTemplate>(), V8TestOverloadedConstructors::internalFieldCount,
         0, 0,
-        0, 0);
+        0, 0, isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8TestOverloadedConstructors::constructorCallback);
     
@@ -205,7 +205,7 @@ v8::Handle<v8::Object> V8TestOverloadedConstructors::createWrapper(PassRefPtr<Te
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index 1d2e0c55a6eac8e8187ebc621ffab92033a3e0d1..32539589a2a9d4a85be5c970b0597be907af237d 100644 (file)
@@ -45,7 +45,7 @@ public:
     static WrapperTypeInfo info;
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestOverloadedConstructors*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestOverloadedConstructors*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     static v8::Handle<v8::Value> constructor1Callback(const v8::Arguments&);
index 1dc95ea3894e876eacf09593202fcd76581f8221..7c8b7e574869e3439540b685257ddfb845683329 100644 (file)
@@ -257,7 +257,7 @@ static v8::Persistent<v8::FunctionTemplate> ConfigureV8TestSerializedScriptValue
     v8::Local<v8::Signature> defaultSignature;
     defaultSignature = V8DOMConfiguration::configureTemplate(desc, "TestSerializedScriptValueInterface", v8::Persistent<v8::FunctionTemplate>(), V8TestSerializedScriptValueInterface::internalFieldCount,
         V8TestSerializedScriptValueInterfaceAttrs, WTF_ARRAY_LENGTH(V8TestSerializedScriptValueInterfaceAttrs),
-        V8TestSerializedScriptValueInterfaceCallbacks, WTF_ARRAY_LENGTH(V8TestSerializedScriptValueInterfaceCallbacks));
+        V8TestSerializedScriptValueInterfaceCallbacks, WTF_ARRAY_LENGTH(V8TestSerializedScriptValueInterfaceCallbacks), isolate);
     UNUSED_PARAM(defaultSignature); // In some cases, it will not be used.
     desc->SetCallHandler(V8TestSerializedScriptValueInterface::constructorCallback);
     v8::Local<v8::ObjectTemplate> instance = desc->InstanceTemplate();
@@ -323,7 +323,7 @@ v8::Handle<v8::Object> V8TestSerializedScriptValueInterface::createWrapper(PassR
     if (UNLIKELY(wrapper.IsEmpty()))
         return wrapper;
 
-    installPerContextProperties(wrapper, impl.get());
+    installPerContextProperties(wrapper, impl.get(), isolate);
     v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate);
     if (!hasDependentLifetime)
         wrapperHandle.MarkIndependent();
index c0c2c39e47c48a469c72c1d0b2e005a382218448..7899edd13177e5f679f8efd6255085ad0b8fb7f9 100644 (file)
@@ -47,7 +47,7 @@ public:
     static WrapperTypeInfo info;
     static v8::Handle<v8::Value> constructorCallback(const v8::Arguments&);
     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
-    static void installPerContextProperties(v8::Handle<v8::Object>, TestSerializedScriptValueInterface*) { }
+    static void installPerContextProperties(v8::Handle<v8::Object>, TestSerializedScriptValueInterface*, v8::Isolate*) { }
     static void installPerContextPrototypeProperties(v8::Handle<v8::Object>) { }
 private:
     friend v8::Handle<v8::Object> wrap(TestSerializedScriptValueInterface*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
index 8b11331ea1fb900a5e6b36257e5bea9ffa154df1..0bba6fc979fca29c6eca8b8864a245eabda56b32 100644 (file)
 
 namespace WebCore {
 
-void V8DOMConfiguration::batchConfigureAttributes(v8::Handle<v8::ObjectTemplate> instance, 
-                                                  v8::Handle<v8::ObjectTemplate> prototype, 
-                                                  const BatchedAttribute* attributes, 
-                                                  size_t attributeCount)
+void V8DOMConfiguration::batchConfigureAttributes(v8::Handle<v8::ObjectTemplate> instance, v8::Handle<v8::ObjectTemplate> prototype, const BatchedAttribute* attributes, size_t attributeCount, v8::Isolate* isolate)
 {
     for (size_t i = 0; i < attributeCount; ++i)
-        configureAttribute(instance, prototype, attributes[i]);
+        configureAttribute(instance, prototype, attributes[i], isolate);
 }
 
-void V8DOMConfiguration::batchConfigureConstants(v8::Handle<v8::FunctionTemplate> functionDescriptor,
-                                                 v8::Handle<v8::ObjectTemplate> prototype,
-                                                 const BatchedConstant* constants,
-                                                 size_t constantCount)
+void V8DOMConfiguration::batchConfigureConstants(v8::Handle<v8::FunctionTemplate> functionDescriptor, v8::Handle<v8::ObjectTemplate> prototype, const BatchedConstant* constants, size_t constantCount, v8::Isolate* isolate)
 {
     for (size_t i = 0; i < constantCount; ++i) {
         const BatchedConstant* constant = &constants[i];
-        functionDescriptor->Set(v8::String::NewSymbol(constant->name), deprecatedV8Integer(constant->value), v8::ReadOnly);
-        prototype->Set(v8::String::NewSymbol(constant->name), deprecatedV8Integer(constant->value), v8::ReadOnly);
+        functionDescriptor->Set(v8::String::NewSymbol(constant->name), v8Integer(constant->value, isolate), v8::ReadOnly);
+        prototype->Set(v8::String::NewSymbol(constant->name), v8Integer(constant->value, isolate), v8::ReadOnly);
     }
 }
 
-void V8DOMConfiguration::batchConfigureCallbacks(v8::Handle<v8::ObjectTemplate> prototype, 
-                                                 v8::Handle<v8::Signature> signature, 
-                                                 v8::PropertyAttribute attributes,
-                                                 const BatchedCallback* callbacks,
-                                                 size_t callbackCount)
+void V8DOMConfiguration::batchConfigureCallbacks(v8::Handle<v8::ObjectTemplate> prototype, v8::Handle<v8::Signature> signature, v8::PropertyAttribute attributes, const BatchedCallback* callbacks, size_t callbackCount, v8::Isolate*)
 {
     for (size_t i = 0; i < callbackCount; ++i)
         prototype->Set(v8::String::NewSymbol(callbacks[i].name), v8::FunctionTemplate::New(callbacks[i].callback, v8Undefined(), signature), attributes);
 }
 
-v8::Local<v8::Signature> V8DOMConfiguration::configureTemplate(v8::Persistent<v8::FunctionTemplate> functionDescriptor,
-                                                               const char* interfaceName,
-                                                               v8::Persistent<v8::FunctionTemplate> parentClass,
-                                                               size_t fieldCount,
-                                                               const BatchedAttribute* attributes, 
-                                                               size_t attributeCount,
-                                                               const BatchedCallback* callbacks,
-                                                               size_t callbackCount)
+v8::Local<v8::Signature> V8DOMConfiguration::configureTemplate(v8::Persistent<v8::FunctionTemplate> functionDescriptor, const char* interfaceName, v8::Persistent<v8::FunctionTemplate> parentClass,
+    size_t fieldCount, const BatchedAttribute* attributes, size_t attributeCount, const BatchedCallback* callbacks, size_t callbackCount, v8::Isolate* isolate)
 {
     functionDescriptor->SetClassName(v8::String::NewSymbol(interfaceName));
     v8::Local<v8::ObjectTemplate> instance = functionDescriptor->InstanceTemplate();
@@ -79,10 +63,10 @@ v8::Local<v8::Signature> V8DOMConfiguration::configureTemplate(v8::Persistent<v8
     if (!parentClass.IsEmpty())
         functionDescriptor->Inherit(parentClass);
     if (attributeCount)
-        batchConfigureAttributes(instance, functionDescriptor->PrototypeTemplate(), attributes, attributeCount);
+        batchConfigureAttributes(instance, functionDescriptor->PrototypeTemplate(), attributes, attributeCount, isolate);
     v8::Local<v8::Signature> defaultSignature = v8::Signature::New(functionDescriptor);
     if (callbackCount)
-        batchConfigureCallbacks(functionDescriptor->PrototypeTemplate(), defaultSignature, static_cast<v8::PropertyAttribute>(v8::DontDelete), callbacks, callbackCount);
+        batchConfigureCallbacks(functionDescriptor->PrototypeTemplate(), defaultSignature, static_cast<v8::PropertyAttribute>(v8::DontDelete), callbacks, callbackCount, isolate);
     return defaultSignature;
 }
 
index 5222436d7cc33e21cd6691a4fe2a235880789d87..319119c9736716f1329ca1fd6f0f503ebe9e52c8 100644 (file)
@@ -53,15 +53,10 @@ public:
         bool onPrototype;
     };
 
-    static void batchConfigureAttributes(v8::Handle<v8::ObjectTemplate>,
-                                         v8::Handle<v8::ObjectTemplate>,
-                                         const BatchedAttribute*,
-                                         size_t attributeCount);
+    static void batchConfigureAttributes(v8::Handle<v8::ObjectTemplate>, v8::Handle<v8::ObjectTemplate>, const BatchedAttribute*, size_t attributeCount, v8::Isolate*);
 
     template<class ObjectOrTemplate>
-    static inline void configureAttribute(v8::Handle<ObjectOrTemplate> instance,
-                                          v8::Handle<ObjectOrTemplate> prototype,
-                                          const BatchedAttribute& attribute)
+    static inline void configureAttribute(v8::Handle<ObjectOrTemplate> instance, v8::Handle<ObjectOrTemplate> prototype, const BatchedAttribute& attribute, v8::Isolate*)
     {
         (attribute.onPrototype ? prototype : instance)->SetAccessor(v8::String::NewSymbol(attribute.name),
                                                                     attribute.getter,
@@ -79,10 +74,7 @@ public:
         int value;
     };
 
-    static void batchConfigureConstants(v8::Handle<v8::FunctionTemplate>,
-                                        v8::Handle<v8::ObjectTemplate>,
-                                        const BatchedConstant*,
-                                        size_t constantCount);
+    static void batchConfigureConstants(v8::Handle<v8::FunctionTemplate>, v8::Handle<v8::ObjectTemplate>, const BatchedConstant*, size_t constantCount, v8::Isolate*);
 
     // BatchedCallback translates into calls to Set() on the prototype ObjectTemplate.
     struct BatchedCallback {
@@ -90,20 +82,9 @@ public:
         v8::InvocationCallback callback;
     };
 
-    static void batchConfigureCallbacks(v8::Handle<v8::ObjectTemplate>, 
-                                        v8::Handle<v8::Signature>,
-                                        v8::PropertyAttribute,
-                                        const BatchedCallback*, 
-                                        size_t callbackCount);
+    static void batchConfigureCallbacks(v8::Handle<v8::ObjectTemplate>, v8::Handle<v8::Signature>, v8::PropertyAttribute, const BatchedCallback*, size_t callbackCount, v8::Isolate*);
 
-    static v8::Local<v8::Signature> configureTemplate(v8::Persistent<v8::FunctionTemplate>,
-                                                      const char* interfaceName,
-                                                      v8::Persistent<v8::FunctionTemplate> parentClass,
-                                                      size_t fieldCount,
-                                                      const BatchedAttribute*,
-                                                      size_t attributeCount,
-                                                      const BatchedCallback*,
-                                                      size_t callbackCount);
+    static v8::Local<v8::Signature> configureTemplate(v8::Persistent<v8::FunctionTemplate>, const char* interfaceName, v8::Persistent<v8::FunctionTemplate> parentClass, size_t fieldCount, const BatchedAttribute*, size_t attributeCount, const BatchedCallback*, size_t callbackCount, v8::Isolate*);
 };
 
 } // namespace WebCore
index a926546748ac1ea952ac938d84745c87a8cbebc0..ca600999321f38d1cbf5652675c0e7ce9999cb9b 100644 (file)
@@ -315,7 +315,7 @@ bool V8DOMWindowShell::installDOMWindow()
     if (windowWrapper.IsEmpty())
         return false;
 
-    V8DOMWindow::installPerContextProperties(windowWrapper, window);
+    V8DOMWindow::installPerContextProperties(windowWrapper, window, m_isolate);
 
     V8DOMWrapper::setNativeInfo(v8::Handle<v8::Object>::Cast(windowWrapper->GetPrototype()), &V8DOMWindow::info, window);