| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 // DO NOT EDIT | 5 // DO NOT EDIT |
| 6 // Auto-generated dart:html library. | 6 // Auto-generated dart:html library. |
| 7 | 7 |
| 8 #library('dart:html'); | 8 #library('dart:html'); |
| 9 | 9 |
| 10 #import('dart:isolate'); | 10 #import('dart:isolate'); |
| 11 #import('dart:json'); | 11 #import('dart:json'); |
| 12 | 12 |
| 13 $!GENERATED_DART_FILES | 13 $!GENERATED_DART_FILES |
| 14 | 14 |
| 15 #source('$AUXILIARY_DIR/CrossFrameTypes.dart'); |
| 15 #source('$AUXILIARY_DIR/EventListener.dart'); | 16 #source('$AUXILIARY_DIR/EventListener.dart'); |
| 16 #source('$AUXILIARY_DIR/KeyLocation.dart'); | 17 #source('$AUXILIARY_DIR/KeyLocation.dart'); |
| 17 #source('$AUXILIARY_DIR/KeyName.dart'); | 18 #source('$AUXILIARY_DIR/KeyName.dart'); |
| 18 #source('$AUXILIARY_DIR/ReadyState.dart'); | 19 #source('$AUXILIARY_DIR/ReadyState.dart'); |
| 19 #source('$AUXILIARY_DIR/Timer.dart'); | 20 #source('$AUXILIARY_DIR/Timer.dart'); |
| 20 #source('$AUXILIARY_DIR/_Collections.dart'); | 21 #source('$AUXILIARY_DIR/_Collections.dart'); |
| 21 #source('$AUXILIARY_DIR/_HttpRequestUtils.dart'); | 22 #source('$AUXILIARY_DIR/_HttpRequestUtils.dart'); |
| 22 #source('$AUXILIARY_DIR/Isolates.dart'); | 23 #source('$AUXILIARY_DIR/Isolates.dart'); |
| 23 #source('$AUXILIARY_DIR/Measurement.dart'); | 24 #source('$AUXILIARY_DIR/Measurement.dart'); |
| 24 #source('$AUXILIARY_DIR/Serialization.dart'); | 25 #source('$AUXILIARY_DIR/Serialization.dart'); |
| 25 #source('$AUXILIARY_DIR/shared_FactoryProviders.dart'); | 26 #source('$AUXILIARY_DIR/shared_FactoryProviders.dart'); |
| 26 #source('$AUXILIARY_DIR/dart2js_Conversions.dart'); | 27 #source('$AUXILIARY_DIR/dart2js_Conversions.dart'); |
| 27 #source('$AUXILIARY_DIR/dart2js_DOMImplementation.dart'); | 28 #source('$AUXILIARY_DIR/dart2js_DOMImplementation.dart'); |
| 28 #source('$AUXILIARY_DIR/dart2js_FactoryProviders.dart'); | 29 #source('$AUXILIARY_DIR/dart2js_FactoryProviders.dart'); |
| 29 #source('$AUXILIARY_DIR/dart2js_IDBKeyRangeFactoryProvider.dart'); | 30 #source('$AUXILIARY_DIR/dart2js_IDBKeyRangeFactoryProvider.dart'); |
| 30 #source('$AUXILIARY_DIR/dart2js_LocationWrapper.dart'); | 31 #source('$AUXILIARY_DIR/dart2js_LocationWrapper.dart'); |
| 31 #source('$AUXILIARY_DIR/dart2js_MutationObserverSupported.dart'); | 32 #source('$AUXILIARY_DIR/dart2js_MutationObserverSupported.dart'); |
| 32 #source('$AUXILIARY_DIR/dart2js_TypedArrayFactoryProvider.dart'); | 33 #source('$AUXILIARY_DIR/dart2js_TypedArrayFactoryProvider.dart'); |
| 33 #source('$AUXILIARY_DIR/_Testing.dart'); | 34 #source('$AUXILIARY_DIR/_Testing.dart'); |
| 34 #source('$AUXILIARY_DIR/Device.dart'); | 35 #source('$AUXILIARY_DIR/Device.dart'); |
| 35 #source('$AUXILIARY_DIR/_ListIterators.dart'); | 36 #source('$AUXILIARY_DIR/_ListIterators.dart'); |
| 36 #source('$AUXILIARY_DIR/_Lists.dart'); | 37 #source('$AUXILIARY_DIR/_Lists.dart'); |
| 37 | 38 |
| 38 | 39 |
| 39 Window get window() native "return window;"; | 40 LocalWindow get window() native "return window;"; |
| 40 _WindowImpl get _window() native "return window;"; | 41 _LocalWindowImpl get _window() native "return window;"; |
| 41 | 42 |
| 42 Document get document() native "return document;"; | 43 Document get document() native "return document;"; |
| 43 | 44 |
| 44 _DocumentImpl get _document() native "return document;"; | 45 _DocumentImpl get _document() native "return document;"; |
| 45 | 46 |
| 46 Element query(String selector) => _document.query(selector); | 47 Element query(String selector) => _document.query(selector); |
| 47 List<Element> queryAll(String selector) => _document.queryAll(selector); | 48 List<Element> queryAll(String selector) => _document.queryAll(selector); |
| 48 | 49 |
| 49 // Workaround for tags like <cite> that lack their own Element subclass -- | 50 // Workaround for tags like <cite> that lack their own Element subclass -- |
| 50 // Dart issue 1990. | 51 // Dart issue 1990. |
| 51 class _HTMLElementImpl extends _ElementImpl native "*HTMLElement" { | 52 class _HTMLElementImpl extends _ElementImpl native "*HTMLElement" { |
| 52 } | 53 } |
| 53 | 54 |
| 54 // Support for Send/ReceivePortSync. | 55 // Support for Send/ReceivePortSync. |
| 55 int _getNewIsolateId() native r''' | 56 int _getNewIsolateId() native r''' |
| 56 if (!window.$dart$isolate$counter) { | 57 if (!window.$dart$isolate$counter) { |
| 57 window.$dart$isolate$counter = 1; | 58 window.$dart$isolate$counter = 1; |
| 58 } | 59 } |
| 59 return window.$dart$isolate$counter++; | 60 return window.$dart$isolate$counter++; |
| 60 '''; | 61 '''; |
| 61 | 62 |
| 62 // Fast path to invoke JS send port. | 63 // Fast path to invoke JS send port. |
| 63 _callPortSync(int id, message) { | 64 _callPortSync(int id, message) { |
| 64 return JS('var', r'ReceivePortSync.dispatchCall(#, #)', id, message); | 65 return JS('var', r'ReceivePortSync.dispatchCall(#, #)', id, message); |
| 65 } | 66 } |
| 66 | 67 |
| 67 // TODO(vsm): Plumb this properly. | 68 // TODO(vsm): Plumb this properly. |
| 68 spawnDomFunction(f) => spawnFunction(f); | 69 spawnDomFunction(f) => spawnFunction(f); |
| OLD | NEW |