| 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. DO NOT MODIFY! | 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! |
| 6 | 6 |
| 7 #include "config.h" | 7 #include "config.h" |
| 8 #include "V8TestInterfaceNamedConstructor2.h" | 8 #include "V8TestInterfaceNamedConstructor2.h" |
| 9 | 9 |
| 10 #include "bindings/core/v8/ExceptionState.h" | 10 #include "bindings/core/v8/ExceptionState.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 } | 30 } |
| 31 | 31 |
| 32 } // namespace blink | 32 } // namespace blink |
| 33 | 33 |
| 34 void webCoreInitializeScriptWrappableForInterface(blink::TestInterfaceNamedConst
ructor2* object) | 34 void webCoreInitializeScriptWrappableForInterface(blink::TestInterfaceNamedConst
ructor2* object) |
| 35 { | 35 { |
| 36 blink::initializeScriptWrappableForInterface(object); | 36 blink::initializeScriptWrappableForInterface(object); |
| 37 } | 37 } |
| 38 | 38 |
| 39 namespace blink { | 39 namespace blink { |
| 40 const WrapperTypeInfo V8TestInterfaceNamedConstructor2::wrapperTypeInfo = { gin:
:kEmbedderBlink, V8TestInterfaceNamedConstructor2::domTemplate, V8TestInterfaceN
amedConstructor2::derefObject, 0, 0, 0, V8TestInterfaceNamedConstructor2::instal
lConditionallyEnabledMethods, 0, WrapperTypeObjectPrototype, RefCountedObject }; | 40 const WrapperTypeInfo V8TestInterfaceNamedConstructor2::wrapperTypeInfo = { gin:
:kEmbedderBlink, V8TestInterfaceNamedConstructor2::domTemplate, V8TestInterfaceN
amedConstructor2::derefObject, 0, 0, 0, V8TestInterfaceNamedConstructor2::instal
lPerContextEnabledMethods, 0, WrapperTypeObjectPrototype, RefCountedObject }; |
| 41 | 41 |
| 42 namespace TestInterfaceNamedConstructor2V8Internal { | 42 namespace TestInterfaceNamedConstructor2V8Internal { |
| 43 | 43 |
| 44 template <typename T> void V8_USE(T) { } | 44 template <typename T> void V8_USE(T) { } |
| 45 | 45 |
| 46 } // namespace TestInterfaceNamedConstructor2V8Internal | 46 } // namespace TestInterfaceNamedConstructor2V8Internal |
| 47 | 47 |
| 48 const WrapperTypeInfo V8TestInterfaceNamedConstructor2Constructor::wrapperTypeIn
fo = { gin::kEmbedderBlink, V8TestInterfaceNamedConstructor2Constructor::domTemp
late, V8TestInterfaceNamedConstructor2::derefObject, 0, 0, 0, V8TestInterfaceNam
edConstructor2::installConditionallyEnabledMethods, 0, WrapperTypeObjectPrototyp
e, RefCountedObject }; | 48 const WrapperTypeInfo V8TestInterfaceNamedConstructor2Constructor::wrapperTypeIn
fo = { gin::kEmbedderBlink, V8TestInterfaceNamedConstructor2Constructor::domTemp
late, V8TestInterfaceNamedConstructor2::derefObject, 0, 0, 0, V8TestInterfaceNam
edConstructor2::installPerContextEnabledMethods, 0, WrapperTypeObjectPrototype,
RefCountedObject }; |
| 49 | 49 |
| 50 static void V8TestInterfaceNamedConstructor2ConstructorCallback(const v8::Functi
onCallbackInfo<v8::Value>& info) | 50 static void V8TestInterfaceNamedConstructor2ConstructorCallback(const v8::Functi
onCallbackInfo<v8::Value>& info) |
| 51 { | 51 { |
| 52 if (!info.IsConstructCall()) { | 52 if (!info.IsConstructCall()) { |
| 53 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Audi
o"), info.GetIsolate()); | 53 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Audi
o"), info.GetIsolate()); |
| 54 return; | 54 return; |
| 55 } | 55 } |
| 56 | 56 |
| 57 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { | 57 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { |
| 58 v8SetReturnValue(info, info.Holder()); | 58 v8SetReturnValue(info, info.Holder()); |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 const WrapperTypeInfo* actualInfo = ScriptWrappable::fromObject(impl.get
())->typeInfo(); | 142 const WrapperTypeInfo* actualInfo = ScriptWrappable::fromObject(impl.get
())->typeInfo(); |
| 143 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have | 143 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have |
| 144 // the same object de-ref functions, though, so use that as the basis of
the check. | 144 // the same object de-ref functions, though, so use that as the basis of
the check. |
| 145 RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(actualInfo->derefObjectFunction
== wrapperTypeInfo.derefObjectFunction); | 145 RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(actualInfo->derefObjectFunction
== wrapperTypeInfo.derefObjectFunction); |
| 146 } | 146 } |
| 147 | 147 |
| 148 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); | 148 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); |
| 149 if (UNLIKELY(wrapper.IsEmpty())) | 149 if (UNLIKELY(wrapper.IsEmpty())) |
| 150 return wrapper; | 150 return wrapper; |
| 151 | 151 |
| 152 installConditionallyEnabledProperties(wrapper, isolate); | 152 installPerContextEnabledProperties(wrapper, impl.get(), isolate); |
| 153 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceNamedConstructor2>(i
mpl, &wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Independent); | 153 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceNamedConstructor2>(i
mpl, &wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Independent); |
| 154 return wrapper; | 154 return wrapper; |
| 155 } | 155 } |
| 156 | 156 |
| 157 void V8TestInterfaceNamedConstructor2::derefObject(void* object) | 157 void V8TestInterfaceNamedConstructor2::derefObject(void* object) |
| 158 { | 158 { |
| 159 fromInternalPointer(object)->deref(); | 159 fromInternalPointer(object)->deref(); |
| 160 } | 160 } |
| 161 | 161 |
| 162 template<> | 162 template<> |
| 163 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNamedConstructor2* impl, v8::Han
dle<v8::Object> creationContext, v8::Isolate* isolate) | 163 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNamedConstructor2* impl, v8::Han
dle<v8::Object> creationContext, v8::Isolate* isolate) |
| 164 { | 164 { |
| 165 return toV8(impl, creationContext, isolate); | 165 return toV8(impl, creationContext, isolate); |
| 166 } | 166 } |
| 167 | 167 |
| 168 } // namespace blink | 168 } // namespace blink |
| OLD | NEW |