| OLD | NEW |
| 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 2796 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2807 $code .= <<END; | 2807 $code .= <<END; |
| 2808 static void ${v8ClassName}ConstructorCallback(const v8::FunctionCallbackInfo<v8:
:Value>& args) | 2808 static void ${v8ClassName}ConstructorCallback(const v8::FunctionCallbackInfo<v8:
:Value>& args) |
| 2809 { | 2809 { |
| 2810 END | 2810 END |
| 2811 $code .= $maybeObserveFeature if $maybeObserveFeature; | 2811 $code .= $maybeObserveFeature if $maybeObserveFeature; |
| 2812 $code .= $maybeDeprecateFeature if $maybeDeprecateFeature; | 2812 $code .= $maybeDeprecateFeature if $maybeDeprecateFeature; |
| 2813 $code .= GenerateConstructorHeader(); | 2813 $code .= GenerateConstructorHeader(); |
| 2814 AddToImplIncludes("V8Document.h"); | 2814 AddToImplIncludes("V8Document.h"); |
| 2815 $code .= <<END; | 2815 $code .= <<END; |
| 2816 Document* document = currentDocument(); | 2816 Document* document = currentDocument(); |
| 2817 ASSERT(document); |
| 2817 | 2818 |
| 2818 // Make sure the document is added to the DOM Node map. Otherwise, the ${imp
lClassName} instance | 2819 // Make sure the document is added to the DOM Node map. Otherwise, the ${imp
lClassName} instance |
| 2819 // may end up being the only node in the map and get garbage-collected prema
turely. | 2820 // may end up being the only node in the map and get garbage-collected prema
turely. |
| 2820 toV8(document, args.Holder(), args.GetIsolate()); | 2821 toV8(document, args.Holder(), args.GetIsolate()); |
| 2821 | 2822 |
| 2822 END | 2823 END |
| 2823 | 2824 |
| 2824 $code .= GenerateArgumentsCountCheck($function, $interface); | 2825 $code .= GenerateArgumentsCountCheck($function, $interface); |
| 2825 | 2826 |
| 2826 if ($raisesExceptions) { | 2827 if ($raisesExceptions) { |
| 2827 AddToImplIncludes("bindings/v8/ExceptionState.h"); | 2828 AddToImplIncludes("bindings/v8/ExceptionState.h"); |
| 2828 $code .= " ExceptionState es(args.GetIsolate());\n"; | 2829 $code .= " ExceptionState es(args.GetIsolate());\n"; |
| 2829 } | 2830 } |
| 2830 | 2831 |
| 2831 my ($parameterCheckString, $paramIndex, %replacements) = GenerateParametersC
heck($function, $interface); | 2832 my ($parameterCheckString, $paramIndex, %replacements) = GenerateParametersC
heck($function, $interface); |
| 2832 $code .= $parameterCheckString; | 2833 $code .= $parameterCheckString; |
| 2833 | 2834 |
| 2834 push(@beforeArgumentList, "document"); | 2835 push(@beforeArgumentList, "*document"); |
| 2835 | 2836 |
| 2836 if ($interface->extendedAttributes->{"ConstructorRaisesException"}) { | 2837 if ($interface->extendedAttributes->{"ConstructorRaisesException"}) { |
| 2837 push(@afterArgumentList, "es"); | 2838 push(@afterArgumentList, "es"); |
| 2838 } | 2839 } |
| 2839 | 2840 |
| 2840 my @argumentList; | 2841 my @argumentList; |
| 2841 my $index = 0; | 2842 my $index = 0; |
| 2842 foreach my $parameter (@{$function->parameters}) { | 2843 foreach my $parameter (@{$function->parameters}) { |
| 2843 last if $index eq $paramIndex; | 2844 last if $index eq $paramIndex; |
| 2844 if ($replacements{$parameter->name}) { | 2845 if ($replacements{$parameter->name}) { |
| (...skipping 3152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5997 if ($currentInterface->extendedAttributes->{$extendedAttribute}) { | 5998 if ($currentInterface->extendedAttributes->{$extendedAttribute}) { |
| 5998 $found = 1; | 5999 $found = 1; |
| 5999 } | 6000 } |
| 6000 return 1 if $found; | 6001 return 1 if $found; |
| 6001 }, 0); | 6002 }, 0); |
| 6002 | 6003 |
| 6003 return $found; | 6004 return $found; |
| 6004 } | 6005 } |
| 6005 | 6006 |
| 6006 1; | 6007 1; |
| OLD | NEW |