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

Side by Side Diff: Source/bindings/tests/results/modules/V8TestInterface5.cpp

Issue 793243004: IDL: Properly support [Exposed] on static methods (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years 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
« no previous file with comments | « Source/bindings/tests/results/core/V8TestInterface.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #if ENABLE(CONDITION) 8 #if ENABLE(CONDITION)
9 #include "V8TestInterface5.h" 9 #include "V8TestInterface5.h"
10 10
(...skipping 774 matching lines...) Expand 10 before | Expand all | Expand 10 after
785 V8DOMConfiguration::installConstants(isolate, functionTemplate, prototypeTem plate, V8TestInterface5Constants, WTF_ARRAY_LENGTH(V8TestInterface5Constants)); 785 V8DOMConfiguration::installConstants(isolate, functionTemplate, prototypeTem plate, V8TestInterface5Constants, WTF_ARRAY_LENGTH(V8TestInterface5Constants));
786 functionTemplate->InstanceTemplate()->SetHandler(v8::IndexedPropertyHandlerC onfiguration(TestInterface5ImplementationV8Internal::indexedPropertyGetterCallba ck, TestInterface5ImplementationV8Internal::indexedPropertySetterCallback, 0, Te stInterface5ImplementationV8Internal::indexedPropertyDeleterCallback, indexedPro pertyEnumerator<TestInterface5Implementation>)); 786 functionTemplate->InstanceTemplate()->SetHandler(v8::IndexedPropertyHandlerC onfiguration(TestInterface5ImplementationV8Internal::indexedPropertyGetterCallba ck, TestInterface5ImplementationV8Internal::indexedPropertySetterCallback, 0, Te stInterface5ImplementationV8Internal::indexedPropertyDeleterCallback, indexedPro pertyEnumerator<TestInterface5Implementation>));
787 functionTemplate->InstanceTemplate()->SetHandler(v8::NamedPropertyHandlerCon figuration(TestInterface5ImplementationV8Internal::namedPropertyGetterCallback, TestInterface5ImplementationV8Internal::namedPropertySetterCallback, TestInterfa ce5ImplementationV8Internal::namedPropertyQueryCallback, TestInterface5Implement ationV8Internal::namedPropertyDeleterCallback, TestInterface5ImplementationV8Int ernal::namedPropertyEnumeratorCallback)); 787 functionTemplate->InstanceTemplate()->SetHandler(v8::NamedPropertyHandlerCon figuration(TestInterface5ImplementationV8Internal::namedPropertyGetterCallback, TestInterface5ImplementationV8Internal::namedPropertySetterCallback, TestInterfa ce5ImplementationV8Internal::namedPropertyQueryCallback, TestInterface5Implement ationV8Internal::namedPropertyDeleterCallback, TestInterface5ImplementationV8Int ernal::namedPropertyEnumeratorCallback));
788 static const V8DOMConfiguration::SymbolKeyedMethodConfiguration symbolKeyedI teratorConfiguration = { v8::Symbol::GetIterator, TestInterface5ImplementationV8 Internal::iteratorMethodCallback, 0, V8DOMConfiguration::ExposedToAllScripts }; 788 static const V8DOMConfiguration::SymbolKeyedMethodConfiguration symbolKeyedI teratorConfiguration = { v8::Symbol::GetIterator, TestInterface5ImplementationV8 Internal::iteratorMethodCallback, 0, V8DOMConfiguration::ExposedToAllScripts };
789 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v8::D ontDelete, symbolKeyedIteratorConfiguration, isolate); 789 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v8::D ontDelete, symbolKeyedIteratorConfiguration, isolate);
790 functionTemplate->InstanceTemplate()->SetCallAsFunctionHandler(V8TestInterfa ce5::legacyCallCustom); 790 functionTemplate->InstanceTemplate()->SetCallAsFunctionHandler(V8TestInterfa ce5::legacyCallCustom);
791 const V8DOMConfiguration::MethodConfiguration alwaysExposedStaticMethodMetho dConfiguration = { 791 const V8DOMConfiguration::MethodConfiguration alwaysExposedStaticMethodMetho dConfiguration = {
792 "alwaysExposedStaticMethod", TestInterface5ImplementationV8Internal::alw aysExposedStaticMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScri pts, 792 "alwaysExposedStaticMethod", TestInterface5ImplementationV8Internal::alw aysExposedStaticMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScri pts,
793 }; 793 };
794 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature> (), v8::None, alwaysExposedStaticMethodMethodConfiguration, isolate); 794 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature> (), v8::None, alwaysExposedStaticMethodMethodConfiguration, isolate);
795 if (context && (context->isWorkerGlobalScope())) {
796 const V8DOMConfiguration::MethodConfiguration workerExposedStaticMethodM ethodConfiguration = {
797 "workerExposedStaticMethod", TestInterface5ImplementationV8Internal: :workerExposedStaticMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAll Scripts,
798 };
799 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signat ure>(), v8::None, workerExposedStaticMethodMethodConfiguration, isolate);
800 }
801 if (context && (context->isDocument())) {
802 const V8DOMConfiguration::MethodConfiguration windowExposedStaticMethodM ethodConfiguration = {
803 "windowExposedStaticMethod", TestInterface5ImplementationV8Internal: :windowExposedStaticMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAll Scripts,
804 };
805 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signat ure>(), v8::None, windowExposedStaticMethodMethodConfiguration, isolate);
806 }
795 const V8DOMConfiguration::MethodConfiguration toStringMethodConfiguration = { 807 const V8DOMConfiguration::MethodConfiguration toStringMethodConfiguration = {
796 "toString", TestInterface5ImplementationV8Internal::toStringMethodCallba ck, 0, 0, V8DOMConfiguration::ExposedToAllScripts, 808 "toString", TestInterface5ImplementationV8Internal::toStringMethodCallba ck, 0, 0, V8DOMConfiguration::ExposedToAllScripts,
797 }; 809 };
798 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, stati c_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toStringMethodConf iguration, isolate); 810 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, stati c_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toStringMethodConf iguration, isolate);
799 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "staticStrin gAttribute"), TestInterface5ImplementationV8Internal::staticStringAttributeAttri buteGetterCallback, TestInterface5ImplementationV8Internal::staticStringAttribut eAttributeSetterCallback, v8::External::New(isolate, 0), static_cast<v8::Propert yAttribute>(v8::None), v8::Handle<v8::AccessorSignature>(), static_cast<v8::Acce ssControl>(v8::DEFAULT)); 811 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "staticStrin gAttribute"), TestInterface5ImplementationV8Internal::staticStringAttributeAttri buteGetterCallback, TestInterface5ImplementationV8Internal::staticStringAttribut eAttributeSetterCallback, v8::External::New(isolate, 0), static_cast<v8::Propert yAttribute>(v8::None), v8::Handle<v8::AccessorSignature>(), static_cast<v8::Acce ssControl>(v8::DEFAULT));
800 812
801 // Custom toString template 813 // Custom toString template
802 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate()); 814 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate());
803 } 815 }
804 816
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
844 v8::Local<v8::Signature> defaultSignature = v8::Signature::New(isolate, domT emplate(isolate)); 856 v8::Local<v8::Signature> defaultSignature = v8::Signature::New(isolate, domT emplate(isolate));
845 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext()); 857 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext());
846 ASSERT(context); 858 ASSERT(context);
847 859
848 if (context && (context->isWorkerGlobalScope())) { 860 if (context && (context->isWorkerGlobalScope())) {
849 prototypeObject->Set(v8AtomicString(isolate, "workerExposedMethod"), v8: :FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::workerEx posedMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetFunction()); 861 prototypeObject->Set(v8AtomicString(isolate, "workerExposedMethod"), v8: :FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::workerEx posedMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetFunction());
850 } 862 }
851 if (context && (context->isDocument())) { 863 if (context && (context->isDocument())) {
852 prototypeObject->Set(v8AtomicString(isolate, "windowExposedMethod"), v8: :FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::windowEx posedMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetFunction()); 864 prototypeObject->Set(v8AtomicString(isolate, "windowExposedMethod"), v8: :FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::windowEx posedMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetFunction());
853 } 865 }
854 if (context && (context->isWorkerGlobalScope())) {
855 prototypeObject->Set(v8AtomicString(isolate, "workerExposedStaticMethod" ), v8::FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::wo rkerExposedStaticMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetF unction());
856 }
857 if (context && (context->isDocument())) {
858 prototypeObject->Set(v8AtomicString(isolate, "windowExposedStaticMethod" ), v8::FunctionTemplate::New(isolate, TestInterface5ImplementationV8Internal::wi ndowExposedStaticMethodMethodCallback, v8Undefined(), defaultSignature, 0)->GetF unction());
859 }
860 if (context && (context->isDocument() || context->isServiceWorkerGlobalScope ())) { 866 if (context && (context->isDocument() || context->isServiceWorkerGlobalScope ())) {
861 prototypeObject->Set(v8AtomicString(isolate, "windowAndServiceWorkerExpo sedMethod"), v8::FunctionTemplate::New(isolate, TestInterface5ImplementationV8In ternal::windowAndServiceWorkerExposedMethodMethodCallback, v8Undefined(), defaul tSignature, 0)->GetFunction()); 867 prototypeObject->Set(v8AtomicString(isolate, "windowAndServiceWorkerExpo sedMethod"), v8::FunctionTemplate::New(isolate, TestInterface5ImplementationV8In ternal::windowAndServiceWorkerExposedMethodMethodCallback, v8Undefined(), defaul tSignature, 0)->GetFunction());
862 } 868 }
863 } 869 }
864 870
865 ActiveDOMObject* V8TestInterface5::toActiveDOMObject(v8::Handle<v8::Object> wrap per) 871 ActiveDOMObject* V8TestInterface5::toActiveDOMObject(v8::Handle<v8::Object> wrap per)
866 { 872 {
867 return toImpl(wrapper); 873 return toImpl(wrapper);
868 } 874 }
869 875
870 void V8TestInterface5::refObject(ScriptWrappable* scriptWrappable) 876 void V8TestInterface5::refObject(ScriptWrappable* scriptWrappable)
871 { 877 {
872 scriptWrappable->toImpl<TestInterface5Implementation>()->ref(); 878 scriptWrappable->toImpl<TestInterface5Implementation>()->ref();
873 } 879 }
874 880
875 void V8TestInterface5::derefObject(ScriptWrappable* scriptWrappable) 881 void V8TestInterface5::derefObject(ScriptWrappable* scriptWrappable)
876 { 882 {
877 scriptWrappable->toImpl<TestInterface5Implementation>()->deref(); 883 scriptWrappable->toImpl<TestInterface5Implementation>()->deref();
878 } 884 }
879 885
880 } // namespace blink 886 } // namespace blink
881 #endif // ENABLE(CONDITION) 887 #endif // ENABLE(CONDITION)
OLDNEW
« no previous file with comments | « Source/bindings/tests/results/core/V8TestInterface.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698