| 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 "V8TestInterfaceEventTarget.h" | 8 #include "V8TestInterfaceEventTarget.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::TestInterfaceEventTarge
t* object) | 34 void webCoreInitializeScriptWrappableForInterface(blink::TestInterfaceEventTarge
t* object) |
| 35 { | 35 { |
| 36 blink::initializeScriptWrappableForInterface(object); | 36 blink::initializeScriptWrappableForInterface(object); |
| 37 } | 37 } |
| 38 | 38 |
| 39 namespace blink { | 39 namespace blink { |
| 40 const WrapperTypeInfo V8TestInterfaceEventTarget::wrapperTypeInfo = { gin::kEmbe
dderBlink, V8TestInterfaceEventTarget::domTemplate, V8TestInterfaceEventTarget::
derefObject, 0, V8TestInterfaceEventTarget::toEventTarget, 0, V8TestInterfaceEve
ntTarget::installPerContextEnabledMethods, &V8EventTarget::wrapperTypeInfo, Wrap
perTypeObjectPrototype, WillBeGarbageCollectedObject }; | 40 const WrapperTypeInfo V8TestInterfaceEventTarget::wrapperTypeInfo = { gin::kEmbe
dderBlink, V8TestInterfaceEventTarget::domTemplate, V8TestInterfaceEventTarget::
derefObject, 0, V8TestInterfaceEventTarget::toEventTarget, 0, V8TestInterfaceEve
ntTarget::installConditionallyEnabledMethods, &V8EventTarget::wrapperTypeInfo, W
rapperTypeObjectPrototype, WillBeGarbageCollectedObject }; |
| 41 | 41 |
| 42 namespace TestInterfaceEventTargetV8Internal { | 42 namespace TestInterfaceEventTargetV8Internal { |
| 43 | 43 |
| 44 template <typename T> void V8_USE(T) { } | 44 template <typename T> void V8_USE(T) { } |
| 45 | 45 |
| 46 } // namespace TestInterfaceEventTargetV8Internal | 46 } // namespace TestInterfaceEventTargetV8Internal |
| 47 | 47 |
| 48 const WrapperTypeInfo V8TestInterfaceEventTargetConstructor::wrapperTypeInfo = {
gin::kEmbedderBlink, V8TestInterfaceEventTargetConstructor::domTemplate, V8Test
InterfaceEventTarget::derefObject, 0, V8TestInterfaceEventTarget::toEventTarget,
0, V8TestInterfaceEventTarget::installPerContextEnabledMethods, 0, WrapperTypeO
bjectPrototype, WillBeGarbageCollectedObject }; | 48 const WrapperTypeInfo V8TestInterfaceEventTargetConstructor::wrapperTypeInfo = {
gin::kEmbedderBlink, V8TestInterfaceEventTargetConstructor::domTemplate, V8Test
InterfaceEventTarget::derefObject, 0, V8TestInterfaceEventTarget::toEventTarget,
0, V8TestInterfaceEventTarget::installConditionallyEnabledMethods, 0, WrapperTy
peObjectPrototype, WillBeGarbageCollectedObject }; |
| 49 | 49 |
| 50 static void V8TestInterfaceEventTargetConstructorCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 50 static void V8TestInterfaceEventTargetConstructorCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 51 { | 51 { |
| 52 if (!info.IsConstructCall()) { | 52 if (!info.IsConstructCall()) { |
| 53 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Name
"), info.GetIsolate()); | 53 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Name
"), 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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 const WrapperTypeInfo* actualInfo = ScriptWrappable::fromObject(impl.get
())->typeInfo(); | 140 const WrapperTypeInfo* actualInfo = ScriptWrappable::fromObject(impl.get
())->typeInfo(); |
| 141 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have | 141 // Might be a XXXConstructor::wrapperTypeInfo instead of an XXX::wrapper
TypeInfo. These will both have |
| 142 // the same object de-ref functions, though, so use that as the basis of
the check. | 142 // the same object de-ref functions, though, so use that as the basis of
the check. |
| 143 RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(actualInfo->derefObjectFunction
== wrapperTypeInfo.derefObjectFunction); | 143 RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(actualInfo->derefObjectFunction
== wrapperTypeInfo.derefObjectFunction); |
| 144 } | 144 } |
| 145 | 145 |
| 146 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); | 146 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); |
| 147 if (UNLIKELY(wrapper.IsEmpty())) | 147 if (UNLIKELY(wrapper.IsEmpty())) |
| 148 return wrapper; | 148 return wrapper; |
| 149 | 149 |
| 150 installPerContextEnabledProperties(wrapper, impl.get(), isolate); | 150 installConditionallyEnabledProperties(wrapper, impl.get(), isolate); |
| 151 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceEventTarget>(impl, &
wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Independent); | 151 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceEventTarget>(impl, &
wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Independent); |
| 152 return wrapper; | 152 return wrapper; |
| 153 } | 153 } |
| 154 | 154 |
| 155 void V8TestInterfaceEventTarget::derefObject(void* object) | 155 void V8TestInterfaceEventTarget::derefObject(void* object) |
| 156 { | 156 { |
| 157 #if !ENABLE(OILPAN) | 157 #if !ENABLE(OILPAN) |
| 158 fromInternalPointer(object)->deref(); | 158 fromInternalPointer(object)->deref(); |
| 159 #endif // !ENABLE(OILPAN) | 159 #endif // !ENABLE(OILPAN) |
| 160 } | 160 } |
| 161 | 161 |
| 162 template<> | 162 template<> |
| 163 v8::Handle<v8::Value> toV8NoInline(TestInterfaceEventTarget* impl, v8::Handle<v8
::Object> creationContext, v8::Isolate* isolate) | 163 v8::Handle<v8::Value> toV8NoInline(TestInterfaceEventTarget* impl, v8::Handle<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 |