| // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| // for details. All rights reserved. Use of this source code is governed by a |
| // BSD-style license that can be found in the LICENSE file. |
| |
| // DO NOT EDIT |
| // Auto-generated dart:html library. |
| |
| library html; |
| |
| import 'dart:isolate'; |
| import 'dart:json'; |
| |
| $!GENERATED_DART_FILES |
| |
| part '$AUXILIARY_DIR/CrossFrameTypes.dart'; |
| part '$AUXILIARY_DIR/EventListener.dart'; |
| part '$AUXILIARY_DIR/KeyLocation.dart'; |
| part '$AUXILIARY_DIR/KeyName.dart'; |
| part '$AUXILIARY_DIR/ReadyState.dart'; |
| part '$AUXILIARY_DIR/Timer.dart'; |
| part '$AUXILIARY_DIR/_Collections.dart'; |
| part '$AUXILIARY_DIR/_HttpRequestUtils.dart'; |
| part '$AUXILIARY_DIR/Isolates.dart'; |
| part '$AUXILIARY_DIR/Measurement.dart'; |
| part '$AUXILIARY_DIR/Serialization.dart'; |
| part '$AUXILIARY_DIR/shared_FactoryProviders.dart'; |
| part '$AUXILIARY_DIR/dart2js_Conversions.dart'; |
| part '$AUXILIARY_DIR/dart2js_DOMImplementation.dart'; |
| part '$AUXILIARY_DIR/dart2js_FactoryProviders.dart'; |
| part '$AUXILIARY_DIR/dart2js_IDBKeyRangeFactoryProvider.dart'; |
| part '$AUXILIARY_DIR/dart2js_LocationWrapper.dart'; |
| part '$AUXILIARY_DIR/dart2js_MutationObserverSupported.dart'; |
| part '$AUXILIARY_DIR/dart2js_TypedArrayFactoryProvider.dart'; |
| part '$AUXILIARY_DIR/_Testing.dart'; |
| part '$AUXILIARY_DIR/Device.dart'; |
| part '$AUXILIARY_DIR/_ListIterators.dart'; |
| part '$AUXILIARY_DIR/_Lists.dart'; |
| |
| |
| LocalWindow get window => JS('LocalWindow', 'window'); |
| _LocalWindowImpl get _window => JS('_LocalWindowImpl', 'window'); |
| |
| Document get document => JS('Document', 'document'); |
| |
| _DocumentImpl get _document => JS('_DocumentImpl', 'document'); |
| |
| Element query(String selector) => _document.query(selector); |
| List<Element> queryAll(String selector) => _document.queryAll(selector); |
| |
| // Workaround for tags like <cite> that lack their own Element subclass -- |
| // Dart issue 1990. |
| class _HTMLElementImpl extends _ElementImpl native "*HTMLElement" { |
| } |
| |
| // Support for Send/ReceivePortSync. |
| int _getNewIsolateId() { |
| if (JS('bool', r'!window.$dart$isolate$counter')) { |
| JS('void', r'window.$dart$isolate$counter = 1'); |
| } |
| return JS('int', r'window.$dart$isolate$counter++'); |
| } |
| |
| // Fast path to invoke JS send port. |
| _callPortSync(int id, message) { |
| return JS('var', r'ReceivePortSync.dispatchCall(#, #)', id, message); |
| } |
| |
| // TODO(vsm): Plumb this properly. |
| spawnDomFunction(f) => spawnFunction(f); |