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

Side by Side Diff: Source/bindings/scripts/code_generator_v8.pm

Issue 36793003: IDL compiler: constructor attributes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 2 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
« no previous file with comments | « no previous file | Source/bindings/scripts/unstable/v8_attributes.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (C) 2005, 2006 Nikolas Zimmermann <zimmermann@kde.org> 1 # Copyright (C) 2005, 2006 Nikolas Zimmermann <zimmermann@kde.org>
2 # Copyright (C) 2006 Anders Carlsson <andersca@mac.com> 2 # Copyright (C) 2006 Anders Carlsson <andersca@mac.com>
3 # Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com> 3 # Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com>
4 # Copyright (C) 2006 Alexey Proskuryakov <ap@webkit.org> 4 # Copyright (C) 2006 Alexey Proskuryakov <ap@webkit.org>
5 # Copyright (C) 2006 Apple Computer, Inc. 5 # Copyright (C) 2006 Apple Computer, Inc.
6 # Copyright (C) 2007, 2008, 2009, 2012 Google Inc. 6 # Copyright (C) 2007, 2008, 2009, 2012 Google Inc.
7 # Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> 7 # Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au>
8 # Copyright (C) Research In Motion Limited 2010. All rights reserved. 8 # Copyright (C) Research In Motion Limited 2010. All rights reserved.
9 # Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 9 # Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
10 # Copyright (C) 2012 Ericsson AB. All rights reserved. 10 # Copyright (C) 2012 Ericsson AB. All rights reserved.
(...skipping 1228 matching lines...) Expand 10 before | Expand all | Expand 10 after
1239 $implementation{nameSpaceInternal}->add(<<END); 1239 $implementation{nameSpaceInternal}->add(<<END);
1240 static void ${implClassName}ConstructorGetter(v8::Local<v8::String> name, const v8::PropertyCallbackInfo<v8::Value>& info) 1240 static void ${implClassName}ConstructorGetter(v8::Local<v8::String> name, const v8::PropertyCallbackInfo<v8::Value>& info)
1241 { 1241 {
1242 v8::Handle<v8::Value> data = info.Data(); 1242 v8::Handle<v8::Value> data = info.Data();
1243 ASSERT(data->IsExternal()); 1243 ASSERT(data->IsExternal());
1244 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre ationContext()); 1244 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre ationContext());
1245 if (!perContextData) 1245 if (!perContextData)
1246 return; 1246 return;
1247 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u nwrap(data))); 1247 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u nwrap(data)));
1248 } 1248 }
1249
1249 END 1250 END
1250 } 1251 }
1251 1252
1252 sub GenerateFeatureObservation 1253 sub GenerateFeatureObservation
1253 { 1254 {
1254 my $measureAs = shift; 1255 my $measureAs = shift;
1255 1256
1256 if ($measureAs) { 1257 if ($measureAs) {
1257 AddToImplIncludes("core/page/UseCounter.h"); 1258 AddToImplIncludes("core/page/UseCounter.h");
1258 return " UseCounter::count(activeDOMWindow(), UseCounter::${measureAs });\n"; 1259 return " UseCounter::count(activeDOMWindow(), UseCounter::${measureAs });\n";
(...skipping 4937 matching lines...) Expand 10 before | Expand all | Expand 10 after
6196 my $interface = shift; 6197 my $interface = shift;
6197 6198
6198 return 1 if $interface->extendedAttributes->{"CustomToV8"}; 6199 return 1 if $interface->extendedAttributes->{"CustomToV8"};
6199 return 1 if $interface->extendedAttributes->{"SpecialWrapFor"}; 6200 return 1 if $interface->extendedAttributes->{"SpecialWrapFor"};
6200 return 1 if InheritsInterface($interface, "Document"); 6201 return 1 if InheritsInterface($interface, "Document");
6201 6202
6202 return 0; 6203 return 0;
6203 } 6204 }
6204 6205
6205 1; 6206 1;
OLDNEW
« no previous file with comments | « no previous file | Source/bindings/scripts/unstable/v8_attributes.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698