Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(332)

Side by Side Diff: Source/bindings/tests/results/V8TestInterface.cpp

Issue 127723002: Add use counters for using Attrs as Nodes. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Bring patch to head. Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 17 matching lines...) Expand all
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 #if ENABLE(Condition1) || ENABLE(Condition2) 34 #if ENABLE(Condition1) || ENABLE(Condition2)
35 #include "V8TestInterface.h" 35 #include "V8TestInterface.h"
36 36
37 #include "RuntimeEnabledFeatures.h" 37 #include "RuntimeEnabledFeatures.h"
38 #include "V8Attr.h"
38 #include "V8Node.h" 39 #include "V8Node.h"
39 #include "V8NodeList.h" 40 #include "V8NodeList.h"
40 #include "V8ReferencedType.h" 41 #include "V8ReferencedType.h"
41 #include "V8TestObject.h" 42 #include "V8TestObject.h"
42 #include "bindings/tests/idls/TestImplements.h" 43 #include "bindings/tests/idls/TestImplements.h"
43 #include "bindings/tests/idls/TestPartialInterface.h" 44 #include "bindings/tests/idls/TestPartialInterface.h"
44 #include "bindings/v8/ExceptionState.h" 45 #include "bindings/v8/ExceptionState.h"
45 #include "bindings/v8/V8AbstractEventListener.h" 46 #include "bindings/v8/V8AbstractEventListener.h"
46 #include "bindings/v8/V8DOMConfiguration.h" 47 #include "bindings/v8/V8DOMConfiguration.h"
47 #include "bindings/v8/V8EventListenerList.h" 48 #include "bindings/v8/V8EventListenerList.h"
48 #include "bindings/v8/V8ObjectConstructor.h" 49 #include "bindings/v8/V8ObjectConstructor.h"
49 #include "core/dom/ContextFeatures.h" 50 #include "core/dom/ContextFeatures.h"
50 #include "core/dom/Document.h" 51 #include "core/dom/Document.h"
52 #include "core/frame/UseCounter.h"
51 #include "platform/TraceEvent.h" 53 #include "platform/TraceEvent.h"
52 #include "wtf/GetPtr.h" 54 #include "wtf/GetPtr.h"
53 #include "wtf/RefPtr.h" 55 #include "wtf/RefPtr.h"
54 56
55 namespace WebCore { 57 namespace WebCore {
56 58
57 static void initializeScriptWrappableForInterface(TestInterface* object) 59 static void initializeScriptWrappableForInterface(TestInterface* object)
58 { 60 {
59 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) 61 if (ScriptWrappable::wrapperCanBeStoredInObject(object))
60 ScriptWrappable::setTypeInfoInObject(object, &V8TestInterface::wrapperTy peInfo); 62 ScriptWrappable::setTypeInfoInObject(object, &V8TestInterface::wrapperTy peInfo);
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 static void implementsNodeAttributeSetter(v8::Local<v8::Value> jsValue, const v8 ::PropertyCallbackInfo<void>& info) 189 static void implementsNodeAttributeSetter(v8::Local<v8::Value> jsValue, const v8 ::PropertyCallbackInfo<void>& info)
188 { 190 {
189 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 191 TestInterface* imp = V8TestInterface::toNative(info.Holder());
190 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 192 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
191 TestImplements::setImplementsNode(imp, WTF::getPtr(cppValue)); 193 TestImplements::setImplementsNode(imp, WTF::getPtr(cppValue));
192 } 194 }
193 195
194 static void implementsNodeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) 196 static void implementsNodeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info)
195 { 197 {
196 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 198 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
199 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
200 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
197 TestInterfaceV8Internal::implementsNodeAttributeSetter(jsValue, info); 201 TestInterfaceV8Internal::implementsNodeAttributeSetter(jsValue, info);
198 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 202 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
199 } 203 }
200 204
201 static void eventHandlerAttributeAttributeGetter(const v8::PropertyCallbackInfo< v8::Value>& info) 205 static void eventHandlerAttributeAttributeGetter(const v8::PropertyCallbackInfo< v8::Value>& info)
202 { 206 {
203 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 207 TestInterface* imp = V8TestInterface::toNative(info.Holder());
204 EventListener* jsValue = TestImplements::eventHandlerAttribute(imp, isolated WorldForIsolate(info.GetIsolate())); 208 EventListener* jsValue = TestImplements::eventHandlerAttribute(imp, isolated WorldForIsolate(info.GetIsolate()));
205 v8SetReturnValue(info, jsValue ? v8::Handle<v8::Value>(V8AbstractEventListen er::cast(jsValue)->getListenerObject(imp->executionContext())) : v8::Handle<v8:: Value>(v8::Null(info.GetIsolate()))); 209 v8SetReturnValue(info, jsValue ? v8::Handle<v8::Value>(V8AbstractEventListen er::cast(jsValue)->getListenerObject(imp->executionContext())) : v8::Handle<v8:: Value>(v8::Null(info.GetIsolate())));
206 } 210 }
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 static void Node23AttributeSetter(v8::Local<v8::Value> jsValue, const v8::Proper tyCallbackInfo<void>& info) 246 static void Node23AttributeSetter(v8::Local<v8::Value> jsValue, const v8::Proper tyCallbackInfo<void>& info)
243 { 247 {
244 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 248 TestInterface* imp = V8TestInterface::toNative(info.Holder());
245 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 249 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
246 TestImplements::setNode23(imp, WTF::getPtr(cppValue)); 250 TestImplements::setNode23(imp, WTF::getPtr(cppValue));
247 } 251 }
248 252
249 static void Node23AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info) 253 static void Node23AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info)
250 { 254 {
251 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 255 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
256 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
257 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
252 TestInterfaceV8Internal::Node23AttributeSetter(jsValue, info); 258 TestInterfaceV8Internal::Node23AttributeSetter(jsValue, info);
253 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 259 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
254 } 260 }
255 261
256 static void Node24AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o) 262 static void Node24AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o)
257 { 263 {
258 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 264 TestInterface* imp = V8TestInterface::toNative(info.Holder());
259 v8SetReturnValueFast(info, TestImplements::node24(imp), imp); 265 v8SetReturnValueFast(info, TestImplements::node24(imp), imp);
260 } 266 }
261 267
262 static void Node24AttributeGetterCallback(v8::Local<v8::String>, const v8::Prope rtyCallbackInfo<v8::Value>& info) 268 static void Node24AttributeGetterCallback(v8::Local<v8::String>, const v8::Prope rtyCallbackInfo<v8::Value>& info)
263 { 269 {
264 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); 270 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
265 TestInterfaceV8Internal::Node24AttributeGetter(info); 271 TestInterfaceV8Internal::Node24AttributeGetter(info);
266 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 272 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
267 } 273 }
268 274
269 static void Node24AttributeSetter(v8::Local<v8::Value> jsValue, const v8::Proper tyCallbackInfo<void>& info) 275 static void Node24AttributeSetter(v8::Local<v8::Value> jsValue, const v8::Proper tyCallbackInfo<void>& info)
270 { 276 {
271 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 277 TestInterface* imp = V8TestInterface::toNative(info.Holder());
272 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 278 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
273 TestImplements::setNode24(imp, WTF::getPtr(cppValue)); 279 TestImplements::setNode24(imp, WTF::getPtr(cppValue));
274 } 280 }
275 281
276 static void Node24AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info) 282 static void Node24AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info)
277 { 283 {
278 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 284 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
285 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
286 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
279 TestInterfaceV8Internal::Node24AttributeSetter(jsValue, info); 287 TestInterfaceV8Internal::Node24AttributeSetter(jsValue, info);
280 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 288 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
281 } 289 }
282 290
283 #if ENABLE(CONDITION_PARTIAL) 291 #if ENABLE(CONDITION_PARTIAL)
284 static void supplementalStaticReadOnlyAttrAttributeGetter(const v8::PropertyCall backInfo<v8::Value>& info) 292 static void supplementalStaticReadOnlyAttrAttributeGetter(const v8::PropertyCall backInfo<v8::Value>& info)
285 { 293 {
286 v8SetReturnValueInt(info, TestPartialInterface::supplementalStaticReadOnlyAt tr()); 294 v8SetReturnValueInt(info, TestPartialInterface::supplementalStaticReadOnlyAt tr());
287 } 295 }
288 #endif // ENABLE(CONDITION_PARTIAL) 296 #endif // ENABLE(CONDITION_PARTIAL)
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
422 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 430 TestInterface* imp = V8TestInterface::toNative(info.Holder());
423 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 431 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
424 TestPartialInterface::setSupplementalNode(imp, WTF::getPtr(cppValue)); 432 TestPartialInterface::setSupplementalNode(imp, WTF::getPtr(cppValue));
425 } 433 }
426 #endif // ENABLE(CONDITION_PARTIAL) 434 #endif // ENABLE(CONDITION_PARTIAL)
427 435
428 #if ENABLE(CONDITION_PARTIAL) 436 #if ENABLE(CONDITION_PARTIAL)
429 static void supplementalNodeAttributeSetterCallback(v8::Local<v8::String>, v8::L ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) 437 static void supplementalNodeAttributeSetterCallback(v8::Local<v8::String>, v8::L ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info)
430 { 438 {
431 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 439 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
440 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
441 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
432 TestInterfaceV8Internal::supplementalNodeAttributeSetter(jsValue, info); 442 TestInterfaceV8Internal::supplementalNodeAttributeSetter(jsValue, info);
433 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 443 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
434 } 444 }
435 #endif // ENABLE(CONDITION_PARTIAL) 445 #endif // ENABLE(CONDITION_PARTIAL)
436 446
437 #if ENABLE(CONDITION_PARTIAL) 447 #if ENABLE(CONDITION_PARTIAL)
438 static void Node13AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o) 448 static void Node13AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o)
439 { 449 {
440 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 450 TestInterface* imp = V8TestInterface::toNative(info.Holder());
441 v8SetReturnValueFast(info, TestPartialInterface::node13(imp), imp); 451 v8SetReturnValueFast(info, TestPartialInterface::node13(imp), imp);
(...skipping 15 matching lines...) Expand all
457 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 467 TestInterface* imp = V8TestInterface::toNative(info.Holder());
458 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 468 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
459 TestPartialInterface::setNode13(imp, WTF::getPtr(cppValue)); 469 TestPartialInterface::setNode13(imp, WTF::getPtr(cppValue));
460 } 470 }
461 #endif // ENABLE(CONDITION_PARTIAL) 471 #endif // ENABLE(CONDITION_PARTIAL)
462 472
463 #if ENABLE(CONDITION_PARTIAL) 473 #if ENABLE(CONDITION_PARTIAL)
464 static void Node13AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info) 474 static void Node13AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info)
465 { 475 {
466 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 476 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
477 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
478 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
467 TestInterfaceV8Internal::Node13AttributeSetter(jsValue, info); 479 TestInterfaceV8Internal::Node13AttributeSetter(jsValue, info);
468 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 480 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
469 } 481 }
470 #endif // ENABLE(CONDITION_PARTIAL) 482 #endif // ENABLE(CONDITION_PARTIAL)
471 483
472 #if ENABLE(CONDITION_PARTIAL) 484 #if ENABLE(CONDITION_PARTIAL)
473 static void Node14AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o) 485 static void Node14AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o)
474 { 486 {
475 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 487 TestInterface* imp = V8TestInterface::toNative(info.Holder());
476 v8SetReturnValueFast(info, TestPartialInterface::node14(imp), imp); 488 v8SetReturnValueFast(info, TestPartialInterface::node14(imp), imp);
(...skipping 15 matching lines...) Expand all
492 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 504 TestInterface* imp = V8TestInterface::toNative(info.Holder());
493 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 505 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
494 TestPartialInterface::setNode14(imp, WTF::getPtr(cppValue)); 506 TestPartialInterface::setNode14(imp, WTF::getPtr(cppValue));
495 } 507 }
496 #endif // ENABLE(CONDITION_PARTIAL) 508 #endif // ENABLE(CONDITION_PARTIAL)
497 509
498 #if ENABLE(CONDITION_PARTIAL) 510 #if ENABLE(CONDITION_PARTIAL)
499 static void Node14AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info) 511 static void Node14AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info)
500 { 512 {
501 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 513 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
514 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
515 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
502 TestInterfaceV8Internal::Node14AttributeSetter(jsValue, info); 516 TestInterfaceV8Internal::Node14AttributeSetter(jsValue, info);
503 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 517 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
504 } 518 }
505 #endif // ENABLE(CONDITION_PARTIAL) 519 #endif // ENABLE(CONDITION_PARTIAL)
506 520
507 #if ENABLE(CONDITION_PARTIAL) 521 #if ENABLE(CONDITION_PARTIAL)
508 static void Node15AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o) 522 static void Node15AttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& inf o)
509 { 523 {
510 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 524 TestInterface* imp = V8TestInterface::toNative(info.Holder());
511 v8SetReturnValueFast(info, TestPartialInterface::node15(imp), imp); 525 v8SetReturnValueFast(info, TestPartialInterface::node15(imp), imp);
(...skipping 15 matching lines...) Expand all
527 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 541 TestInterface* imp = V8TestInterface::toNative(info.Holder());
528 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0); 542 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca st(jsValue)) : 0);
529 TestPartialInterface::setNode15(imp, WTF::getPtr(cppValue)); 543 TestPartialInterface::setNode15(imp, WTF::getPtr(cppValue));
530 } 544 }
531 #endif // ENABLE(CONDITION_PARTIAL) 545 #endif // ENABLE(CONDITION_PARTIAL)
532 546
533 #if ENABLE(CONDITION_PARTIAL) 547 #if ENABLE(CONDITION_PARTIAL)
534 static void Node15AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info) 548 static void Node15AttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::V alue> jsValue, const v8::PropertyCallbackInfo<void>& info)
535 { 549 {
536 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 550 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
551 if (V8DOMWrapper::isWrapperOfType(jsValue, &V8Attr::wrapperTypeInfo))
552 UseCounter::count(activeExecutionContext(), UseCounter::AttrUsedAsNodePa rameter);
537 TestInterfaceV8Internal::Node15AttributeSetter(jsValue, info); 553 TestInterfaceV8Internal::Node15AttributeSetter(jsValue, info);
538 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 554 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
539 } 555 }
540 #endif // ENABLE(CONDITION_PARTIAL) 556 #endif // ENABLE(CONDITION_PARTIAL)
541 557
542 static void implementsMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& i nfo) 558 static void implementsMethod1Method(const v8::FunctionCallbackInfo<v8::Value>& i nfo)
543 { 559 {
544 TestInterface* imp = V8TestInterface::toNative(info.Holder()); 560 TestInterface* imp = V8TestInterface::toNative(info.Holder());
545 TestImplements::implementsMethod1(imp); 561 TestImplements::implementsMethod1(imp);
546 } 562 }
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
982 } 998 }
983 999
984 template<> 1000 template<>
985 v8::Handle<v8::Value> toV8NoInline(TestInterface* impl, v8::Handle<v8::Object> c reationContext, v8::Isolate* isolate) 1001 v8::Handle<v8::Value> toV8NoInline(TestInterface* impl, v8::Handle<v8::Object> c reationContext, v8::Isolate* isolate)
986 { 1002 {
987 return toV8(impl, creationContext, isolate); 1003 return toV8(impl, creationContext, isolate);
988 } 1004 }
989 1005
990 } // namespace WebCore 1006 } // namespace WebCore
991 #endif // ENABLE(Condition1) || ENABLE(Condition2) 1007 #endif // ENABLE(Condition1) || ENABLE(Condition2)
OLDNEW
« no previous file with comments | « Source/bindings/tests/results/V8TestEventTarget.cpp ('k') | Source/bindings/tests/results/V8TestObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698