| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // This file has been auto-generated by code_generator_v8.py. | 5 // This file has been auto-generated by code_generator_v8.py. |
| 6 // DO NOT MODIFY! | 6 // DO NOT MODIFY! |
| 7 | 7 |
| 8 // This file has been generated from the Jinja2 template in | 8 // This file has been generated from the Jinja2 template in |
| 9 // third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl | 9 // third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl |
| 10 | 10 |
| (...skipping 928 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 939 v8::Local<v8::Object> V8TestInterface5::findInstanceInPrototypeChain(v8::Local<v
8::Value> v8Value, v8::Isolate* isolate) { | 939 v8::Local<v8::Object> V8TestInterface5::findInstanceInPrototypeChain(v8::Local<v
8::Value> v8Value, v8::Isolate* isolate) { |
| 940 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrapperT
ypeInfo, v8Value); | 940 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrapperT
ypeInfo, v8Value); |
| 941 } | 941 } |
| 942 | 942 |
| 943 TestInterface5Implementation* V8TestInterface5::toImplWithTypeCheck(v8::Isolate*
isolate, v8::Local<v8::Value> value) { | 943 TestInterface5Implementation* V8TestInterface5::toImplWithTypeCheck(v8::Isolate*
isolate, v8::Local<v8::Value> value) { |
| 944 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(value)
) : nullptr; | 944 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(value)
) : nullptr; |
| 945 } | 945 } |
| 946 | 946 |
| 947 void V8TestInterface5::preparePrototypeAndInterfaceObject(v8::Local<v8::Context>
context, const DOMWrapperWorld& world, v8::Local<v8::Object> prototypeObject, v
8::Local<v8::Function> interfaceObject, v8::Local<v8::FunctionTemplate> interfac
eTemplate) { | 947 void V8TestInterface5::preparePrototypeAndInterfaceObject(v8::Local<v8::Context>
context, const DOMWrapperWorld& world, v8::Local<v8::Object> prototypeObject, v
8::Local<v8::Function> interfaceObject, v8::Local<v8::FunctionTemplate> interfac
eTemplate) { |
| 948 v8::Isolate* isolate = context->GetIsolate(); | 948 v8::Isolate* isolate = context->GetIsolate(); |
| 949 ExecutionContext* executionContext = toExecutionContext(context); | 949 { |
| 950 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTemp
late); | 950 ExecutionContext* executionContext = toExecutionContext(context); |
| 951 if (executionContext && (executionContext->isWorkerGlobalScope())) { | 951 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTe
mplate); |
| 952 const V8DOMConfiguration::AccessorConfiguration accessorConfiguration = {"wo
rkerExposedAttribute", V8TestInterface5::workerExposedAttributeAttributeGetterCa
llback, V8TestInterface5::workerExposedAttributeAttributeSetterCallback, nullptr
, nullptr, nullptr, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8DOM
Configuration::OnPrototype, V8DOMConfiguration::CheckHolder}; | 952 if (executionContext && (executionContext->isWorkerGlobalScope())) { |
| 953 V8DOMConfiguration::installAccessor(isolate, world, v8::Local<v8::Object>(),
prototypeObject, interfaceObject, signature, accessorConfiguration); | 953 const V8DOMConfiguration::AccessorConfiguration accessorConfiguration = {"
workerExposedAttribute", V8TestInterface5::workerExposedAttributeAttributeGetter
Callback, V8TestInterface5::workerExposedAttributeAttributeSetterCallback, nullp
tr, nullptr, nullptr, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8D
OMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; |
| 954 } | 954 V8DOMConfiguration::installAccessor(isolate, world, v8::Local<v8::Object>(
), prototypeObject, interfaceObject, signature, accessorConfiguration); |
| 955 if (executionContext && (executionContext->isDocument())) { | 955 } |
| 956 const V8DOMConfiguration::AccessorConfiguration accessorConfiguration = {"wi
ndowExposedAttribute", V8TestInterface5::windowExposedAttributeAttributeGetterCa
llback, V8TestInterface5::windowExposedAttributeAttributeSetterCallback, nullptr
, nullptr, nullptr, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8DOM
Configuration::OnPrototype, V8DOMConfiguration::CheckHolder}; | 956 if (executionContext && (executionContext->isDocument())) { |
| 957 V8DOMConfiguration::installAccessor(isolate, world, v8::Local<v8::Object>(),
prototypeObject, interfaceObject, signature, accessorConfiguration); | 957 const V8DOMConfiguration::AccessorConfiguration accessorConfiguration = {"
windowExposedAttribute", V8TestInterface5::windowExposedAttributeAttributeGetter
Callback, V8TestInterface5::windowExposedAttributeAttributeSetterCallback, nullp
tr, nullptr, nullptr, nullptr, static_cast<v8::PropertyAttribute>(v8::None), V8D
OMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; |
| 958 V8DOMConfiguration::installAccessor(isolate, world, v8::Local<v8::Object>(
), prototypeObject, interfaceObject, signature, accessorConfiguration); |
| 959 } |
| 958 } | 960 } |
| 959 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTemp
late); | 961 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTemp
late); |
| 960 ExecutionContext* executionContext = toExecutionContext(prototypeObject->Creat
ionContext()); | 962 ExecutionContext* executionContext = toExecutionContext(prototypeObject->Creat
ionContext()); |
| 961 DCHECK(executionContext); | 963 DCHECK(executionContext); |
| 962 if (executionContext && (executionContext->isWorkerGlobalScope())) { | 964 if (executionContext && (executionContext->isWorkerGlobalScope())) { |
| 963 const V8DOMConfiguration::MethodConfiguration workerExposedMethodMethodConfi
guration = {"workerExposedMethod", V8TestInterface5::workerExposedMethodMethodCa
llback, nullptr, 0, v8::None, V8DOMConfiguration::OnPrototype, V8DOMConfiguratio
n::CheckHolder}; | 965 const V8DOMConfiguration::MethodConfiguration workerExposedMethodMethodConfi
guration = {"workerExposedMethod", V8TestInterface5::workerExposedMethodMethodCa
llback, nullptr, 0, v8::None, V8DOMConfiguration::OnPrototype, V8DOMConfiguratio
n::CheckHolder}; |
| 964 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, workerExposedMethodMethodConfigurati
on); | 966 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, workerExposedMethodMethodConfigurati
on); |
| 965 } | 967 } |
| 966 if (executionContext && (executionContext->isDocument())) { | 968 if (executionContext && (executionContext->isDocument())) { |
| 967 const V8DOMConfiguration::MethodConfiguration windowExposedMethodMethodConfi
guration = {"windowExposedMethod", V8TestInterface5::windowExposedMethodMethodCa
llback, nullptr, 0, v8::None, V8DOMConfiguration::OnPrototype, V8DOMConfiguratio
n::CheckHolder}; | 969 const V8DOMConfiguration::MethodConfiguration windowExposedMethodMethodConfi
guration = {"windowExposedMethod", V8TestInterface5::windowExposedMethodMethodCa
llback, nullptr, 0, v8::None, V8DOMConfiguration::OnPrototype, V8DOMConfiguratio
n::CheckHolder}; |
| 968 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowExposedMethodMethodConfigurati
on); | 970 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowExposedMethodMethodConfigurati
on); |
| 969 } | 971 } |
| 970 if (executionContext && (executionContext->isWorkerGlobalScope())) { | 972 if (executionContext && (executionContext->isWorkerGlobalScope())) { |
| 971 const V8DOMConfiguration::MethodConfiguration workerExposedStaticMethodMetho
dConfiguration = {"workerExposedStaticMethod", V8TestInterface5::workerExposedSt
aticMethodMethodCallback, nullptr, 0, v8::None, V8DOMConfiguration::OnInterface,
V8DOMConfiguration::CheckHolder}; | 973 const V8DOMConfiguration::MethodConfiguration workerExposedStaticMethodMetho
dConfiguration = {"workerExposedStaticMethod", V8TestInterface5::workerExposedSt
aticMethodMethodCallback, nullptr, 0, v8::None, V8DOMConfiguration::OnInterface,
V8DOMConfiguration::CheckHolder}; |
| 972 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, workerExposedStaticMethodMethodConfi
guration); | 974 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, workerExposedStaticMethodMethodConfi
guration); |
| 973 } | 975 } |
| 974 if (executionContext && (executionContext->isDocument())) { | 976 if (executionContext && (executionContext->isDocument())) { |
| 975 const V8DOMConfiguration::MethodConfiguration windowExposedStaticMethodMetho
dConfiguration = {"windowExposedStaticMethod", V8TestInterface5::windowExposedSt
aticMethodMethodCallback, nullptr, 0, v8::None, V8DOMConfiguration::OnInterface,
V8DOMConfiguration::CheckHolder}; | 977 const V8DOMConfiguration::MethodConfiguration windowExposedStaticMethodMetho
dConfiguration = {"windowExposedStaticMethod", V8TestInterface5::windowExposedSt
aticMethodMethodCallback, nullptr, 0, v8::None, V8DOMConfiguration::OnInterface,
V8DOMConfiguration::CheckHolder}; |
| 976 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowExposedStaticMethodMethodConfi
guration); | 978 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowExposedStaticMethodMethodConfi
guration); |
| 977 } | 979 } |
| 978 if (executionContext && (executionContext->isDocument() || executionContext->i
sServiceWorkerGlobalScope())) { | 980 if (executionContext && (executionContext->isDocument() || executionContext->i
sServiceWorkerGlobalScope())) { |
| 979 const V8DOMConfiguration::MethodConfiguration windowAndServiceWorkerExposedM
ethodMethodConfiguration = {"windowAndServiceWorkerExposedMethod", V8TestInterfa
ce5::windowAndServiceWorkerExposedMethodMethodCallback, nullptr, 0, v8::None, V8
DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; | 981 const V8DOMConfiguration::MethodConfiguration windowAndServiceWorkerExposedM
ethodMethodConfiguration = {"windowAndServiceWorkerExposedMethod", V8TestInterfa
ce5::windowAndServiceWorkerExposedMethodMethodCallback, nullptr, 0, v8::None, V8
DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; |
| 980 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowAndServiceWorkerExposedMethodM
ethodConfiguration); | 982 V8DOMConfiguration::installMethod(isolate, world, v8::Local<v8::Object>(), p
rototypeObject, interfaceObject, signature, windowAndServiceWorkerExposedMethodM
ethodConfiguration); |
| 981 } | 983 } |
| 982 } | 984 } |
| 983 | 985 |
| 984 } // namespace blink | 986 } // namespace blink |
| OLD | NEW |