| 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 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 } | 483 } |
| 484 | 484 |
| 485 sub HeaderFilesForInterface | 485 sub HeaderFilesForInterface |
| 486 { | 486 { |
| 487 my $interfaceName = shift; | 487 my $interfaceName = shift; |
| 488 my $implClassName = shift; | 488 my $implClassName = shift; |
| 489 | 489 |
| 490 my @includes = (); | 490 my @includes = (); |
| 491 if (IsPrimitiveType($interfaceName) or IsEnumType($interfaceName) or IsCallb
ackFunctionType($interfaceName)) { | 491 if (IsPrimitiveType($interfaceName) or IsEnumType($interfaceName) or IsCallb
ackFunctionType($interfaceName)) { |
| 492 # Not interface type, no header files | 492 # Not interface type, no header files |
| 493 } elsif (IsTypedArrayType($interfaceName)) { | |
| 494 push(@includes, "wtf/${interfaceName}.h"); | |
| 495 } else { | 493 } else { |
| 496 my $idlFilename = Cwd::abs_path(IDLFileForInterface($interfaceName)) or
die("Could NOT find IDL file for interface \"$interfaceName\" $!\n"); | 494 my $idlFilename = Cwd::abs_path(IDLFileForInterface($interfaceName)) or
die("Could NOT find IDL file for interface \"$interfaceName\" $!\n"); |
| 497 my $idlRelPath = File::Spec->abs2rel($idlFilename, $sourceRoot); | 495 my $idlRelPath = File::Spec->abs2rel($idlFilename, $sourceRoot); |
| 498 push(@includes, dirname($idlRelPath) . "/" . $implClassName . ".h"); | 496 push(@includes, dirname($idlRelPath) . "/" . $implClassName . ".h"); |
| 499 } | 497 } |
| 500 return @includes; | 498 return @includes; |
| 501 } | 499 } |
| 502 | 500 |
| 503 sub NeedsVisitDOMWrapper | 501 sub NeedsVisitDOMWrapper |
| 504 { | 502 { |
| (...skipping 4632 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5137 } | 5135 } |
| 5138 END | 5136 END |
| 5139 } | 5137 } |
| 5140 | 5138 |
| 5141 $code .= <<END; | 5139 $code .= <<END; |
| 5142 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); | 5140 v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext
, &wrapperTypeInfo, toInternalPointer(impl.get()), isolate); |
| 5143 if (UNLIKELY(wrapper.IsEmpty())) | 5141 if (UNLIKELY(wrapper.IsEmpty())) |
| 5144 return wrapper; | 5142 return wrapper; |
| 5145 | 5143 |
| 5146 END | 5144 END |
| 5147 if (IsTypedArrayType($interface->name)) { | |
| 5148 AddToImplIncludes("bindings/v8/custom/V8ArrayBufferCustom.h"); | |
| 5149 $code .= <<END; | |
| 5150 impl->buffer()->setDeallocationObserver(V8ArrayBufferDeallocationObserver::i
nstanceTemplate()); | |
| 5151 END | |
| 5152 } | |
| 5153 | |
| 5154 if (InheritsInterface($interface, "AudioBuffer")) { | 5145 if (InheritsInterface($interface, "AudioBuffer")) { |
| 5155 AddToImplIncludes("modules/webaudio/AudioBuffer.h"); | 5146 AddToImplIncludes("modules/webaudio/AudioBuffer.h"); |
| 5156 $code .= <<END; | 5147 $code .= <<END; |
| 5157 for (unsigned i = 0, n = impl->numberOfChannels(); i < n; i++) { | 5148 for (unsigned i = 0, n = impl->numberOfChannels(); i < n; i++) { |
| 5158 Float32Array* channelData = impl->getChannelData(i); | 5149 Float32Array* channelData = impl->getChannelData(i); |
| 5159 channelData->buffer()->setDeallocationObserver(V8ArrayBufferDeallocation
Observer::instanceTemplate()); | 5150 channelData->buffer()->setDeallocationObserver(V8ArrayBufferDeallocation
Observer::instanceTemplate()); |
| 5160 } | 5151 } |
| 5161 END | 5152 END |
| 5162 } | 5153 } |
| 5163 | 5154 |
| (...skipping 1236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6400 if ($parameter->type eq "SerializedScriptValue") { | 6391 if ($parameter->type eq "SerializedScriptValue") { |
| 6401 return 1; | 6392 return 1; |
| 6402 } elsif (IsIntegerType($parameter->type)) { | 6393 } elsif (IsIntegerType($parameter->type)) { |
| 6403 return 1; | 6394 return 1; |
| 6404 } | 6395 } |
| 6405 } | 6396 } |
| 6406 return 0; | 6397 return 0; |
| 6407 } | 6398 } |
| 6408 | 6399 |
| 6409 1; | 6400 1; |
| OLD | NEW |