| 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 5351 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5362 my $getIsolate = shift; | 5362 my $getIsolate = shift; |
| 5363 | 5363 |
| 5364 my $intConversion = $extendedAttributes->{"EnforceRange"} ? "EnforceRange" :
"NormalConversion"; | 5364 my $intConversion = $extendedAttributes->{"EnforceRange"} ? "EnforceRange" :
"NormalConversion"; |
| 5365 | 5365 |
| 5366 return "$value->BooleanValue()" if $type eq "boolean"; | 5366 return "$value->BooleanValue()" if $type eq "boolean"; |
| 5367 return "static_cast<$type>($value->NumberValue())" if $type eq "float" or $t
ype eq "double"; | 5367 return "static_cast<$type>($value->NumberValue())" if $type eq "float" or $t
ype eq "double"; |
| 5368 | 5368 |
| 5369 if ($intConversion ne "NormalConversion") { | 5369 if ($intConversion ne "NormalConversion") { |
| 5370 return "toInt8($value, $intConversion, ok)" if $type eq "byte"; | 5370 return "toInt8($value, $intConversion, ok)" if $type eq "byte"; |
| 5371 return "toUInt8($value, $intConversion, ok)" if $type eq "octet"; | 5371 return "toUInt8($value, $intConversion, ok)" if $type eq "octet"; |
| 5372 return "toInt32($value, $intConversion, ok)" if $type eq "long" or $type
eq "short"; | 5372 return "toInt16($value, $intConversion, ok)" if $type eq "short"; |
| 5373 return "toUInt32($value, $intConversion, ok)" if $type eq "unsigned long
" or $type eq "unsigned short"; | 5373 return "toUInt16($value, $intConversion, ok)" if $type eq "unsigned shor
t"; |
| 5374 return "toInt32($value, $intConversion, ok)" if $type eq "long"; |
| 5375 return "toUInt32($value, $intConversion, ok)" if $type eq "unsigned long
"; |
| 5374 return "toInt64($value, $intConversion, ok)" if $type eq "long long"; | 5376 return "toInt64($value, $intConversion, ok)" if $type eq "long long"; |
| 5375 return "toUInt64($value, $intConversion, ok)" if $type eq "unsigned long
long"; | 5377 return "toUInt64($value, $intConversion, ok)" if $type eq "unsigned long
long"; |
| 5376 } else { | 5378 } else { |
| 5377 return "toInt8($value)" if $type eq "byte"; | 5379 return "toInt8($value)" if $type eq "byte"; |
| 5378 return "toUInt8($value)" if $type eq "octet"; | 5380 return "toUInt8($value)" if $type eq "octet"; |
| 5379 return "toInt32($value)" if $type eq "long" or $type eq "short"; | 5381 return "toInt16($value)" if $type eq "short"; |
| 5380 return "toUInt32($value)" if $type eq "unsigned long" or $type eq "unsig
ned short"; | 5382 return "toUInt16($value)" if $type eq "unsigned short"; |
| 5383 return "toInt32($value)" if $type eq "long"; |
| 5384 return "toUInt32($value)" if $type eq "unsigned long"; |
| 5381 return "toInt64($value)" if $type eq "long long"; | 5385 return "toInt64($value)" if $type eq "long long"; |
| 5382 return "toUInt64($value)" if $type eq "unsigned long long"; | 5386 return "toUInt64($value)" if $type eq "unsigned long long"; |
| 5383 } | 5387 } |
| 5384 return "static_cast<Range::CompareHow>($value->Int32Value())" if $type eq "C
ompareHow"; | 5388 return "static_cast<Range::CompareHow>($value->Int32Value())" if $type eq "C
ompareHow"; |
| 5385 return "toWebCoreDate($value)" if $type eq "Date"; | 5389 return "toWebCoreDate($value)" if $type eq "Date"; |
| 5386 | 5390 |
| 5387 if ($type eq "DOMString" or IsEnumType($type)) { | 5391 if ($type eq "DOMString" or IsEnumType($type)) { |
| 5388 return $value; | 5392 return $value; |
| 5389 } | 5393 } |
| 5390 | 5394 |
| (...skipping 894 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6285 | 6289 |
| 6286 return 1 if $interface->extendedAttributes->{"CustomToV8"}; | 6290 return 1 if $interface->extendedAttributes->{"CustomToV8"}; |
| 6287 return 1 if $interface->extendedAttributes->{"SpecialWrapFor"}; | 6291 return 1 if $interface->extendedAttributes->{"SpecialWrapFor"}; |
| 6288 return 1 if InheritsInterface($interface, "Document"); | 6292 return 1 if InheritsInterface($interface, "Document"); |
| 6289 return 1 if SVGTypeNeedsToHoldContextElement($interface->name); | 6293 return 1 if SVGTypeNeedsToHoldContextElement($interface->name); |
| 6290 | 6294 |
| 6291 return 0; | 6295 return 0; |
| 6292 } | 6296 } |
| 6293 | 6297 |
| 6294 1; | 6298 1; |
| OLD | NEW |