| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 // This file has been auto-generated by code_generator_v8.pm. DO NOT MODIFY! | 31 // This file has been auto-generated by code_generator_v8.pm. DO NOT MODIFY! |
| 32 | 32 |
| 33 #include "config.h" | 33 #include "config.h" |
| 34 #include "V8TestEventTarget.h" | 34 #include "V8TestEventTarget.h" |
| 35 | 35 |
| 36 #include "RuntimeEnabledFeatures.h" | 36 #include "RuntimeEnabledFeatures.h" |
| 37 #include "V8Attr.h" | |
| 38 #include "V8Node.h" | 37 #include "V8Node.h" |
| 39 #include "bindings/v8/ExceptionState.h" | 38 #include "bindings/v8/ExceptionState.h" |
| 40 #include "bindings/v8/V8DOMConfiguration.h" | 39 #include "bindings/v8/V8DOMConfiguration.h" |
| 41 #include "bindings/v8/V8ObjectConstructor.h" | 40 #include "bindings/v8/V8ObjectConstructor.h" |
| 42 #include "core/dom/ContextFeatures.h" | 41 #include "core/dom/ContextFeatures.h" |
| 43 #include "core/dom/Document.h" | 42 #include "core/dom/Document.h" |
| 44 #include "core/frame/UseCounter.h" | |
| 45 #include "platform/TraceEvent.h" | 43 #include "platform/TraceEvent.h" |
| 46 #include "wtf/GetPtr.h" | 44 #include "wtf/GetPtr.h" |
| 47 #include "wtf/RefPtr.h" | 45 #include "wtf/RefPtr.h" |
| 48 | 46 |
| 49 namespace WebCore { | 47 namespace WebCore { |
| 50 | 48 |
| 51 static void initializeScriptWrappableForInterface(TestEventTarget* object) | 49 static void initializeScriptWrappableForInterface(TestEventTarget* object) |
| 52 { | 50 { |
| 53 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) | 51 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) |
| 54 ScriptWrappable::setTypeInfoInObject(object, &V8TestEventTarget::wrapper
TypeInfo); | 52 ScriptWrappable::setTypeInfoInObject(object, &V8TestEventTarget::wrapper
TypeInfo); |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 | 122 |
| 125 static void indexedPropertyGetterCallback(uint32_t index, const v8::PropertyCall
backInfo<v8::Value>& info) | 123 static void indexedPropertyGetterCallback(uint32_t index, const v8::PropertyCall
backInfo<v8::Value>& info) |
| 126 { | 124 { |
| 127 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMIndexedProperty"); | 125 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMIndexedProperty"); |
| 128 TestEventTargetV8Internal::indexedPropertyGetter(index, info); | 126 TestEventTargetV8Internal::indexedPropertyGetter(index, info); |
| 129 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 127 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 130 } | 128 } |
| 131 | 129 |
| 132 static void indexedPropertySetter(uint32_t index, v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<v8::Value>& info) | 130 static void indexedPropertySetter(uint32_t index, v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 133 { | 131 { |
| 134 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo)) | |
| 135 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa
rameter); | |
| 136 TestEventTarget* collection = V8TestEventTarget::toNative(info.Holder()); | 132 TestEventTarget* collection = V8TestEventTarget::toNative(info.Holder()); |
| 137 V8TRYCATCH_VOID(Node*, propertyValue, V8Node::hasInstance(jsValue, info.GetI
solate(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object
>::Cast(jsValue)) : 0); | 133 V8TRYCATCH_VOID(Node*, propertyValue, V8Node::hasInstance(jsValue, info.GetI
solate(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object
>::Cast(jsValue)) : 0); |
| 138 bool result = collection->anonymousIndexedSetter(index, propertyValue); | 134 bool result = collection->anonymousIndexedSetter(index, propertyValue); |
| 139 if (!result) | 135 if (!result) |
| 140 return; | 136 return; |
| 141 v8SetReturnValue(info, jsValue); | 137 v8SetReturnValue(info, jsValue); |
| 142 } | 138 } |
| 143 | 139 |
| 144 static void indexedPropertySetterCallback(uint32_t index, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<v8::Value>& info) | 140 static void indexedPropertySetterCallback(uint32_t index, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 145 { | 141 { |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 359 fromInternalPointer(object)->deref(); | 355 fromInternalPointer(object)->deref(); |
| 360 } | 356 } |
| 361 | 357 |
| 362 template<> | 358 template<> |
| 363 v8::Handle<v8::Value> toV8NoInline(TestEventTarget* impl, v8::Handle<v8::Object>
creationContext, v8::Isolate* isolate) | 359 v8::Handle<v8::Value> toV8NoInline(TestEventTarget* impl, v8::Handle<v8::Object>
creationContext, v8::Isolate* isolate) |
| 364 { | 360 { |
| 365 return toV8(impl, creationContext, isolate); | 361 return toV8(impl, creationContext, isolate); |
| 366 } | 362 } |
| 367 | 363 |
| 368 } // namespace WebCore | 364 } // namespace WebCore |
| OLD | NEW |