| 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 "V8SVGTestInterface.h" | 8 #include "V8SVGTestInterface.h" |
| 9 | 9 |
| 10 #include "bindings/core/v8/ExceptionState.h" | 10 #include "bindings/core/v8/ExceptionState.h" |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 // bindings/core/v8/ScriptWrappable.h. | 43 // bindings/core/v8/ScriptWrappable.h. |
| 44 const WrapperTypeInfo& SVGTestInterface::s_wrapperTypeInfo = V8SVGTestInterface:
:wrapperTypeInfo; | 44 const WrapperTypeInfo& SVGTestInterface::s_wrapperTypeInfo = V8SVGTestInterface:
:wrapperTypeInfo; |
| 45 | 45 |
| 46 namespace SVGTestInterfaceV8Internal { | 46 namespace SVGTestInterfaceV8Internal { |
| 47 | 47 |
| 48 template <typename T> void V8_USE(T) { } | 48 template <typename T> void V8_USE(T) { } |
| 49 | 49 |
| 50 static void typeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 50 static void typeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 51 { | 51 { |
| 52 v8::Handle<v8::Object> holder = info.Holder(); | 52 v8::Handle<v8::Object> holder = info.Holder(); |
| 53 SVGTestInterface* impl = V8SVGTestInterface::toNative(holder); | 53 SVGTestInterface* impl = V8SVGTestInterface::toImpl(holder); |
| 54 v8SetReturnValueString(info, impl->fastGetAttribute(SVGNames::typeAttr), inf
o.GetIsolate()); | 54 v8SetReturnValueString(info, impl->fastGetAttribute(SVGNames::typeAttr), inf
o.GetIsolate()); |
| 55 } | 55 } |
| 56 | 56 |
| 57 static void typeAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) | 57 static void typeAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) |
| 58 { | 58 { |
| 59 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); | 59 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); |
| 60 SVGTestInterfaceV8Internal::typeAttributeGetter(info); | 60 SVGTestInterfaceV8Internal::typeAttributeGetter(info); |
| 61 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 61 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
| 62 } | 62 } |
| 63 | 63 |
| 64 static void typeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::Property
CallbackInfo<void>& info) | 64 static void typeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::Property
CallbackInfo<void>& info) |
| 65 { | 65 { |
| 66 v8::Handle<v8::Object> holder = info.Holder(); | 66 v8::Handle<v8::Object> holder = info.Holder(); |
| 67 SVGTestInterface* impl = V8SVGTestInterface::toNative(holder); | 67 SVGTestInterface* impl = V8SVGTestInterface::toImpl(holder); |
| 68 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); | 68 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); |
| 69 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; | 69 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; |
| 70 impl->setAttribute(SVGNames::typeAttr, cppValue); | 70 impl->setAttribute(SVGNames::typeAttr, cppValue); |
| 71 } | 71 } |
| 72 | 72 |
| 73 static void typeAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val
ue> v8Value, const v8::PropertyCallbackInfo<void>& info) | 73 static void typeAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val
ue> v8Value, const v8::PropertyCallbackInfo<void>& info) |
| 74 { | 74 { |
| 75 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); | 75 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); |
| 76 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; | 76 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; |
| 77 SVGTestInterfaceV8Internal::typeAttributeSetter(v8Value, info); | 77 SVGTestInterfaceV8Internal::typeAttributeSetter(v8Value, info); |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 bool V8SVGTestInterface::hasInstance(v8::Handle<v8::Value> v8Value, v8::Isolate*
isolate) | 109 bool V8SVGTestInterface::hasInstance(v8::Handle<v8::Value> v8Value, v8::Isolate*
isolate) |
| 110 { | 110 { |
| 111 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, v8Valu
e); | 111 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, v8Valu
e); |
| 112 } | 112 } |
| 113 | 113 |
| 114 v8::Handle<v8::Object> V8SVGTestInterface::findInstanceInPrototypeChain(v8::Hand
le<v8::Value> v8Value, v8::Isolate* isolate) | 114 v8::Handle<v8::Object> V8SVGTestInterface::findInstanceInPrototypeChain(v8::Hand
le<v8::Value> v8Value, v8::Isolate* isolate) |
| 115 { | 115 { |
| 116 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe
rTypeInfo, v8Value); | 116 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe
rTypeInfo, v8Value); |
| 117 } | 117 } |
| 118 | 118 |
| 119 SVGTestInterface* V8SVGTestInterface::toNativeWithTypeCheck(v8::Isolate* isolate
, v8::Handle<v8::Value> value) | 119 SVGTestInterface* V8SVGTestInterface::toImplWithTypeCheck(v8::Isolate* isolate,
v8::Handle<v8::Value> value) |
| 120 { | 120 { |
| 121 return hasInstance(value, isolate) ? fromInternalPointer(blink::toInternalPo
inter(v8::Handle<v8::Object>::Cast(value))) : 0; | 121 return hasInstance(value, isolate) ? blink::toScriptWrappableBase(v8::Handle
<v8::Object>::Cast(value))->toImpl<SVGTestInterface>() : 0; |
| 122 } | 122 } |
| 123 | 123 |
| 124 | 124 |
| 125 void V8SVGTestInterface::refObject(ScriptWrappableBase* internalPointer) | 125 void V8SVGTestInterface::refObject(ScriptWrappableBase* internalPointer) |
| 126 { | 126 { |
| 127 fromInternalPointer(internalPointer)->ref(); | 127 internalPointer->toImpl<SVGTestInterface>()->ref(); |
| 128 } | 128 } |
| 129 | 129 |
| 130 void V8SVGTestInterface::derefObject(ScriptWrappableBase* internalPointer) | 130 void V8SVGTestInterface::derefObject(ScriptWrappableBase* internalPointer) |
| 131 { | 131 { |
| 132 fromInternalPointer(internalPointer)->deref(); | 132 internalPointer->toImpl<SVGTestInterface>()->deref(); |
| 133 } | 133 } |
| 134 | 134 |
| 135 WrapperPersistentNode* V8SVGTestInterface::createPersistentHandle(ScriptWrappabl
eBase* internalPointer) | 135 WrapperPersistentNode* V8SVGTestInterface::createPersistentHandle(ScriptWrappabl
eBase* internalPointer) |
| 136 { | 136 { |
| 137 ASSERT_NOT_REACHED(); | 137 ASSERT_NOT_REACHED(); |
| 138 return 0; | 138 return 0; |
| 139 } | 139 } |
| 140 | 140 |
| 141 template<> | 141 template<> |
| 142 v8::Handle<v8::Value> toV8NoInline(SVGTestInterface* impl, v8::Handle<v8::Object
> creationContext, v8::Isolate* isolate) | 142 v8::Handle<v8::Value> toV8NoInline(SVGTestInterface* impl, v8::Handle<v8::Object
> creationContext, v8::Isolate* isolate) |
| 143 { | 143 { |
| 144 return toV8(impl, creationContext, isolate); | 144 return toV8(impl, creationContext, isolate); |
| 145 } | 145 } |
| 146 | 146 |
| 147 } // namespace blink | 147 } // namespace blink |
| OLD | NEW |