| 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" |
| 37 #include "V8Node.h" | 38 #include "V8Node.h" |
| 38 #include "bindings/v8/ExceptionState.h" | 39 #include "bindings/v8/ExceptionState.h" |
| 39 #include "bindings/v8/V8DOMConfiguration.h" | 40 #include "bindings/v8/V8DOMConfiguration.h" |
| 40 #include "bindings/v8/V8ObjectConstructor.h" | 41 #include "bindings/v8/V8ObjectConstructor.h" |
| 41 #include "core/dom/ContextFeatures.h" | 42 #include "core/dom/ContextFeatures.h" |
| 42 #include "core/dom/Document.h" | 43 #include "core/dom/Document.h" |
| 44 #include "core/frame/UseCounter.h" |
| 43 #include "platform/TraceEvent.h" | 45 #include "platform/TraceEvent.h" |
| 44 #include "wtf/GetPtr.h" | 46 #include "wtf/GetPtr.h" |
| 45 #include "wtf/RefPtr.h" | 47 #include "wtf/RefPtr.h" |
| 46 | 48 |
| 47 namespace WebCore { | 49 namespace WebCore { |
| 48 | 50 |
| 49 static void initializeScriptWrappableForInterface(TestEventTarget* object) | 51 static void initializeScriptWrappableForInterface(TestEventTarget* object) |
| 50 { | 52 { |
| 51 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) | 53 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) |
| 52 ScriptWrappable::setTypeInfoInObject(object, &V8TestEventTarget::wrapper
TypeInfo); | 54 ScriptWrappable::setTypeInfoInObject(object, &V8TestEventTarget::wrapper
TypeInfo); |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 | 124 |
| 123 static void indexedPropertyGetterCallback(uint32_t index, const v8::PropertyCall
backInfo<v8::Value>& info) | 125 static void indexedPropertyGetterCallback(uint32_t index, const v8::PropertyCall
backInfo<v8::Value>& info) |
| 124 { | 126 { |
| 125 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMIndexedProperty"); | 127 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMIndexedProperty"); |
| 126 TestEventTargetV8Internal::indexedPropertyGetter(index, info); | 128 TestEventTargetV8Internal::indexedPropertyGetter(index, info); |
| 127 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 129 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 128 } | 130 } |
| 129 | 131 |
| 130 static void indexedPropertySetter(uint32_t index, v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<v8::Value>& info) | 132 static void indexedPropertySetter(uint32_t index, v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 131 { | 133 { |
| 134 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo)) |
| 135 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa
rameter); |
| 132 TestEventTarget* collection = V8TestEventTarget::toNative(info.Holder()); | 136 TestEventTarget* collection = V8TestEventTarget::toNative(info.Holder()); |
| 133 V8TRYCATCH_VOID(Node*, propertyValue, V8Node::hasInstance(jsValue, info.GetI
solate(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object
>::Cast(jsValue)) : 0); | 137 V8TRYCATCH_VOID(Node*, propertyValue, V8Node::hasInstance(jsValue, info.GetI
solate(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object
>::Cast(jsValue)) : 0); |
| 134 bool result = collection->anonymousIndexedSetter(index, propertyValue); | 138 bool result = collection->anonymousIndexedSetter(index, propertyValue); |
| 135 if (!result) | 139 if (!result) |
| 136 return; | 140 return; |
| 137 v8SetReturnValue(info, jsValue); | 141 v8SetReturnValue(info, jsValue); |
| 138 } | 142 } |
| 139 | 143 |
| 140 static void indexedPropertySetterCallback(uint32_t index, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<v8::Value>& info) | 144 static void indexedPropertySetterCallback(uint32_t index, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 141 { | 145 { |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 355 fromInternalPointer(object)->deref(); | 359 fromInternalPointer(object)->deref(); |
| 356 } | 360 } |
| 357 | 361 |
| 358 template<> | 362 template<> |
| 359 v8::Handle<v8::Value> toV8NoInline(TestEventTarget* impl, v8::Handle<v8::Object>
creationContext, v8::Isolate* isolate) | 363 v8::Handle<v8::Value> toV8NoInline(TestEventTarget* impl, v8::Handle<v8::Object>
creationContext, v8::Isolate* isolate) |
| 360 { | 364 { |
| 361 return toV8(impl, creationContext, isolate); | 365 return toV8(impl, creationContext, isolate); |
| 362 } | 366 } |
| 363 | 367 |
| 364 } // namespace WebCore | 368 } // namespace WebCore |
| OLD | NEW |