| OLD | NEW |
| 1 /** | 1 /** |
| 2 * This library provides entry points to the native Blink code which backs | 2 * This library provides entry points to the native Blink code which backs |
| 3 * up the dart:html library. | 3 * up the dart:html library. |
| 4 */ | 4 */ |
| 5 library dart.dom._blink; | 5 library dart.dom._blink; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 import 'dart:collection'; | 8 import 'dart:collection'; |
| 9 import 'dart:html'; | 9 import 'dart:html'; |
| 10 import 'dart:_internal' hide Symbol, deprecated; | 10 import 'dart:_internal' hide Symbol, deprecated; |
| (...skipping 8115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8126 | 8126 |
| 8127 static $previousSibling_Callback(mthis) native "TreeWalker_previousSibling_Cal
lback_RESOLVER_STRING_0_"; | 8127 static $previousSibling_Callback(mthis) native "TreeWalker_previousSibling_Cal
lback_RESOLVER_STRING_0_"; |
| 8128 } | 8128 } |
| 8129 | 8129 |
| 8130 class BlinkURL { | 8130 class BlinkURL { |
| 8131 // Generated overload resolver | 8131 // Generated overload resolver |
| 8132 static $createObjectUrl(blob_OR_source_OR_stream) { | 8132 static $createObjectUrl(blob_OR_source_OR_stream) { |
| 8133 if ((blob_OR_source_OR_stream is Blob || blob_OR_source_OR_stream == null))
{ | 8133 if ((blob_OR_source_OR_stream is Blob || blob_OR_source_OR_stream == null))
{ |
| 8134 return $_createObjectURL_1_Callback(blob_OR_source_OR_stream); | 8134 return $_createObjectURL_1_Callback(blob_OR_source_OR_stream); |
| 8135 } | 8135 } |
| 8136 if ((blob_OR_source_OR_stream is MediaSource || blob_OR_source_OR_stream ==
null)) { | 8136 if ((blob_OR_source_OR_stream is MediaStream || blob_OR_source_OR_stream ==
null)) { |
| 8137 return $_createObjectURL_2_Callback(blob_OR_source_OR_stream); | 8137 return $_createObjectURL_2_Callback(blob_OR_source_OR_stream); |
| 8138 } | 8138 } |
| 8139 if ((blob_OR_source_OR_stream is MediaStream || blob_OR_source_OR_stream ==
null)) { | 8139 if ((blob_OR_source_OR_stream is MediaSource || blob_OR_source_OR_stream ==
null)) { |
| 8140 return $_createObjectURL_3_Callback(blob_OR_source_OR_stream); | 8140 return $_createObjectURL_3_Callback(blob_OR_source_OR_stream); |
| 8141 } | 8141 } |
| 8142 throw new ArgumentError("Incorrect number or type of arguments"); | 8142 throw new ArgumentError("Incorrect number or type of arguments"); |
| 8143 } | 8143 } |
| 8144 | 8144 |
| 8145 static $_createObjectURL_1_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_Blob"; | 8145 static $_createObjectURL_1_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_Blob"; |
| 8146 | 8146 |
| 8147 static $_createObjectURL_2_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_MediaSource"; | 8147 static $_createObjectURL_2_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_MediaStream"; |
| 8148 | 8148 |
| 8149 static $_createObjectURL_3_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_MediaStream"; | 8149 static $_createObjectURL_3_Callback(blob_OR_source_OR_stream) native "URL_crea
teObjectURL_Callback_RESOLVER_STRING_1_MediaSource"; |
| 8150 | 8150 |
| 8151 static $createObjectUrlFromBlob_Callback(blob) native "URL_createObjectURL_Cal
lback_RESOLVER_STRING_1_Blob"; | 8151 static $createObjectUrlFromBlob_Callback(blob) native "URL_createObjectURL_Cal
lback_RESOLVER_STRING_1_Blob"; |
| 8152 | 8152 |
| 8153 static $createObjectUrlFromSource_Callback(source) native "URL_createObjectURL
_Callback_RESOLVER_STRING_1_MediaSource"; | 8153 static $createObjectUrlFromSource_Callback(source) native "URL_createObjectURL
_Callback_RESOLVER_STRING_1_MediaSource"; |
| 8154 | 8154 |
| 8155 static $createObjectUrlFromStream_Callback(stream) native "URL_createObjectURL
_Callback_RESOLVER_STRING_1_MediaStream"; | 8155 static $createObjectUrlFromStream_Callback(stream) native "URL_createObjectURL
_Callback_RESOLVER_STRING_1_MediaStream"; |
| 8156 | 8156 |
| 8157 static $revokeObjectURL_Callback(url) native "URL_revokeObjectURL_Callback_RES
OLVER_STRING_1_DOMString"; | 8157 static $revokeObjectURL_Callback(url) native "URL_revokeObjectURL_Callback_RES
OLVER_STRING_1_DOMString"; |
| 8158 | 8158 |
| 8159 static $hash_Getter(mthis) native "URL_hash_Getter"; | 8159 static $hash_Getter(mthis) native "URL_hash_Getter"; |
| (...skipping 1191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9351 static $setParameter_Callback(mthis, namespaceURI, localName, value) native "X
SLTProcessor_setParameter_Callback"; | 9351 static $setParameter_Callback(mthis, namespaceURI, localName, value) native "X
SLTProcessor_setParameter_Callback"; |
| 9352 | 9352 |
| 9353 static $transformToDocument_Callback(mthis, source) native "XSLTProcessor_tran
sformToDocument_Callback_RESOLVER_STRING_1_Node"; | 9353 static $transformToDocument_Callback(mthis, source) native "XSLTProcessor_tran
sformToDocument_Callback_RESOLVER_STRING_1_Node"; |
| 9354 | 9354 |
| 9355 static $transformToFragment_Callback(mthis, source, docVal) native "XSLTProces
sor_transformToFragment_Callback_RESOLVER_STRING_2_Node_Document"; | 9355 static $transformToFragment_Callback(mthis, source, docVal) native "XSLTProces
sor_transformToFragment_Callback_RESOLVER_STRING_2_Node_Document"; |
| 9356 } | 9356 } |
| 9357 | 9357 |
| 9358 | 9358 |
| 9359 // TODO(vsm): This should be moved out of this library. Into dart:html? | 9359 // TODO(vsm): This should be moved out of this library. Into dart:html? |
| 9360 Type _getType(String key) { | 9360 Type _getType(String key) { |
| 9361 var result; |
| 9362 |
| 9361 // TODO(vsm): Add Cross Frame and JS types here as well. | 9363 // TODO(vsm): Add Cross Frame and JS types here as well. |
| 9362 if (htmlBlinkMap.containsKey(key)) | 9364 |
| 9365 // Check the html library. |
| 9366 result = _getHtmlType(key); |
| 9367 if (result != null) { |
| 9368 return result; |
| 9369 } |
| 9370 |
| 9371 // Check the web gl library. |
| 9372 result = _getWebGlType(key); |
| 9373 if (result != null) { |
| 9374 return result; |
| 9375 } |
| 9376 |
| 9377 // Check the indexed db library. |
| 9378 result = _getIndexDbType(key); |
| 9379 if (result != null) { |
| 9380 return result; |
| 9381 } |
| 9382 |
| 9383 // Check the web audio library. |
| 9384 result = _getWebAudioType(key); |
| 9385 if (result != null) { |
| 9386 return result; |
| 9387 } |
| 9388 |
| 9389 // Check the web sql library. |
| 9390 result = _getWebSqlType(key); |
| 9391 if (result != null) { |
| 9392 return result; |
| 9393 } |
| 9394 |
| 9395 // Check the svg library. |
| 9396 result = _getSvgType(key); |
| 9397 if (result != null) { |
| 9398 return result; |
| 9399 } |
| 9400 |
| 9401 return null; |
| 9402 } |
| 9403 |
| 9404 Type _getHtmlType(String key) { |
| 9405 if (htmlBlinkMap.containsKey(key)) { |
| 9363 return htmlBlinkMap[key](); | 9406 return htmlBlinkMap[key](); |
| 9364 if (indexed_dbBlinkMap.containsKey(key)) | 9407 } |
| 9408 return null; |
| 9409 } |
| 9410 |
| 9411 Type _getWebGlType(String key) { |
| 9412 if (web_glBlinkMap.containsKey(key)) { |
| 9413 return web_glBlinkMap[key](); |
| 9414 } |
| 9415 return null; |
| 9416 } |
| 9417 |
| 9418 Type _getIndexDbType(String key) { |
| 9419 if (indexed_dbBlinkMap.containsKey(key)) { |
| 9365 return indexed_dbBlinkMap[key](); | 9420 return indexed_dbBlinkMap[key](); |
| 9366 if (web_audioBlinkMap.containsKey(key)) | 9421 } |
| 9422 return null; |
| 9423 } |
| 9424 |
| 9425 Type _getWebAudioType(String key) { |
| 9426 if (web_audioBlinkMap.containsKey(key)) { |
| 9367 return web_audioBlinkMap[key](); | 9427 return web_audioBlinkMap[key](); |
| 9368 if (web_glBlinkMap.containsKey(key)) | 9428 } |
| 9369 return web_glBlinkMap[key](); | 9429 return null; |
| 9370 if (web_sqlBlinkMap.containsKey(key)) | 9430 } |
| 9431 |
| 9432 Type _getWebSqlType(String key) { |
| 9433 if (web_sqlBlinkMap.containsKey(key)) { |
| 9371 return web_sqlBlinkMap[key](); | 9434 return web_sqlBlinkMap[key](); |
| 9372 if (svgBlinkMap.containsKey(key)) | 9435 } |
| 9436 return null; |
| 9437 } |
| 9438 |
| 9439 Type _getSvgType(String key) { |
| 9440 if (svgBlinkMap.containsKey(key)) { |
| 9373 return svgBlinkMap[key](); | 9441 return svgBlinkMap[key](); |
| 9442 } |
| 9374 return null; | 9443 return null; |
| 9375 }// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 9444 } |
| 9445 |
| 9446 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
| 9376 // for details. All rights reserved. Use of this source code is governed by a | 9447 // for details. All rights reserved. Use of this source code is governed by a |
| 9377 // BSD-style license that can be found in the LICENSE file. | 9448 // BSD-style license that can be found in the LICENSE file. |
| 9378 | 9449 |
| 9379 | 9450 |
| 9380 // _Utils native entry points | 9451 // _Utils native entry points |
| 9381 class Blink_Utils { | 9452 class Blink_Utils { |
| 9382 static window() native "Utils_window"; | 9453 static window() native "Utils_window"; |
| 9383 | 9454 |
| 9384 static forwardingPrint(message) native "Utils_forwardingPrint"; | 9455 static forwardingPrint(message) native "Utils_forwardingPrint"; |
| 9385 | 9456 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9432 static containsKey(_DOMStringMap, key) native "DOMStringMap_containsKey_Callba
ck"; | 9503 static containsKey(_DOMStringMap, key) native "DOMStringMap_containsKey_Callba
ck"; |
| 9433 | 9504 |
| 9434 static item(_DOMStringMap, key) native "DOMStringMap_item_Callback"; | 9505 static item(_DOMStringMap, key) native "DOMStringMap_item_Callback"; |
| 9435 | 9506 |
| 9436 static setItem(_DOMStringMap, key, value) native "DOMStringMap_setItem_Callbac
k"; | 9507 static setItem(_DOMStringMap, key, value) native "DOMStringMap_setItem_Callbac
k"; |
| 9437 | 9508 |
| 9438 static remove(_DOMStringMap, key) native "DOMStringMap_remove_Callback"; | 9509 static remove(_DOMStringMap, key) native "DOMStringMap_remove_Callback"; |
| 9439 | 9510 |
| 9440 static get_keys(_DOMStringMap) native "DOMStringMap_getKeys_Callback"; | 9511 static get_keys(_DOMStringMap) native "DOMStringMap_getKeys_Callback"; |
| 9441 } | 9512 } |
| OLD | NEW |