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

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

Issue 172033002: Remove WrapperTypeTraits (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 10 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/tests/results/V8TestEventTarget.h » ('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 906 matching lines...) Expand 10 before | Expand all | Expand 10 after
917 917
918 my $customToV8 = ExtendedAttributeContains($interface->extendedAttributes->{ "Custom"}, "ToV8"); 918 my $customToV8 = ExtendedAttributeContains($interface->extendedAttributes->{ "Custom"}, "ToV8");
919 my $passRefPtrType = GetPassRefPtrType($interface); 919 my $passRefPtrType = GetPassRefPtrType($interface);
920 if (!$customToV8) { 920 if (!$customToV8) {
921 $header{classPrivate}->add(<<END); 921 $header{classPrivate}->add(<<END);
922 friend v8::Handle<v8::Object> wrap(${nativeType}*, v8::Handle<v8::Object> cr eationContext, v8::Isolate*); 922 friend v8::Handle<v8::Object> wrap(${nativeType}*, v8::Handle<v8::Object> cr eationContext, v8::Isolate*);
923 static v8::Handle<v8::Object> createWrapper(${passRefPtrType}, v8::Handle<v8 ::Object> creationContext, v8::Isolate*); 923 static v8::Handle<v8::Object> createWrapper(${passRefPtrType}, v8::Handle<v8 ::Object> creationContext, v8::Isolate*);
924 END 924 END
925 } 925 }
926 926
927 $header{nameSpaceWebCore}->add(<<END);
928
929 template<>
930 class WrapperTypeTraits<${nativeType} > {
931 public:
932 static const WrapperTypeInfo* wrapperTypeInfo() { return &${v8ClassName}::wr apperTypeInfo; }
933 };
934 END
935
936 if ($customToV8) { 927 if ($customToV8) {
937 $header{nameSpaceWebCore}->add(<<END); 928 $header{nameSpaceWebCore}->add(<<END);
938 929
939 class ${nativeType}; 930 class ${nativeType};
940 v8::Handle<v8::Value> toV8(${nativeType}*, v8::Handle<v8::Object> creationContex t, v8::Isolate*); 931 v8::Handle<v8::Value> toV8(${nativeType}*, v8::Handle<v8::Object> creationContex t, v8::Isolate*);
941 932
942 template<class CallbackInfo> 933 template<class CallbackInfo>
943 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, ${nativeType}* im pl) 934 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, ${nativeType}* im pl)
944 { 935 {
945 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInf o.GetIsolate())); 936 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInf o.GetIsolate()));
(...skipping 5546 matching lines...) Expand 10 before | Expand all | Expand 10 after
6492 if ($parameter->type eq "SerializedScriptValue") { 6483 if ($parameter->type eq "SerializedScriptValue") {
6493 return 1; 6484 return 1;
6494 } elsif (IsIntegerType($parameter->type)) { 6485 } elsif (IsIntegerType($parameter->type)) {
6495 return 1; 6486 return 1;
6496 } 6487 }
6497 } 6488 }
6498 return 0; 6489 return 0;
6499 } 6490 }
6500 6491
6501 1; 6492 1;
OLDNEW
« no previous file with comments | « no previous file | Source/bindings/tests/results/V8TestEventTarget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698