Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 library html; | 1 library html; |
| 2 | 2 |
| 3 import 'dart:isolate'; | 3 import 'dart:isolate'; |
| 4 import 'dart:json'; | 4 import 'dart:json'; |
| 5 import 'dart:svg' as svg; | 5 import 'dart:svg' as svg; |
| 6 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 6 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 7 // for details. All rights reserved. Use of this source code is governed by a | 7 // for details. All rights reserved. Use of this source code is governed by a |
| 8 // BSD-style license that can be found in the LICENSE file. | 8 // BSD-style license that can be found in the LICENSE file. |
| 9 | 9 |
| 10 // DO NOT EDIT | 10 // DO NOT EDIT |
| (...skipping 1344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1355 /** @domName CSSPrimitiveValue.primitiveType */ | 1355 /** @domName CSSPrimitiveValue.primitiveType */ |
| 1356 final int primitiveType; | 1356 final int primitiveType; |
| 1357 | 1357 |
| 1358 /** @domName CSSPrimitiveValue.getCounterValue */ | 1358 /** @domName CSSPrimitiveValue.getCounterValue */ |
| 1359 Counter getCounterValue() native; | 1359 Counter getCounterValue() native; |
| 1360 | 1360 |
| 1361 /** @domName CSSPrimitiveValue.getFloatValue */ | 1361 /** @domName CSSPrimitiveValue.getFloatValue */ |
| 1362 num getFloatValue(int unitType) native; | 1362 num getFloatValue(int unitType) native; |
| 1363 | 1363 |
| 1364 /** @domName CSSPrimitiveValue.getRGBColorValue */ | 1364 /** @domName CSSPrimitiveValue.getRGBColorValue */ |
| 1365 RGBColor getRGBColorValue() native; | 1365 RGBColor getRgbColorValue() native "getRGBColorValue"; |
| 1366 | 1366 |
| 1367 /** @domName CSSPrimitiveValue.getRectValue */ | 1367 /** @domName CSSPrimitiveValue.getRectValue */ |
| 1368 Rect getRectValue() native; | 1368 Rect getRectValue() native; |
| 1369 | 1369 |
| 1370 /** @domName CSSPrimitiveValue.getStringValue */ | 1370 /** @domName CSSPrimitiveValue.getStringValue */ |
| 1371 String getStringValue() native; | 1371 String getStringValue() native; |
| 1372 | 1372 |
| 1373 /** @domName CSSPrimitiveValue.setFloatValue */ | 1373 /** @domName CSSPrimitiveValue.setFloatValue */ |
| 1374 void setFloatValue(int unitType, num floatValue) native; | 1374 void setFloatValue(int unitType, num floatValue) native; |
| 1375 | 1375 |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1445 /** @domName CSSStyleDeclaration.cssText */ | 1445 /** @domName CSSStyleDeclaration.cssText */ |
| 1446 String cssText; | 1446 String cssText; |
| 1447 | 1447 |
| 1448 /** @domName CSSStyleDeclaration.length */ | 1448 /** @domName CSSStyleDeclaration.length */ |
| 1449 final int length; | 1449 final int length; |
| 1450 | 1450 |
| 1451 /** @domName CSSStyleDeclaration.parentRule */ | 1451 /** @domName CSSStyleDeclaration.parentRule */ |
| 1452 final CSSRule parentRule; | 1452 final CSSRule parentRule; |
| 1453 | 1453 |
| 1454 /** @domName CSSStyleDeclaration.getPropertyCSSValue */ | 1454 /** @domName CSSStyleDeclaration.getPropertyCSSValue */ |
| 1455 CSSValue getPropertyCSSValue(String propertyName) native; | 1455 CSSValue getPropertyCssValue(String propertyName) native "getPropertyCSSValue" ; |
| 1456 | 1456 |
| 1457 /** @domName CSSStyleDeclaration.getPropertyPriority */ | 1457 /** @domName CSSStyleDeclaration.getPropertyPriority */ |
| 1458 String getPropertyPriority(String propertyName) native; | 1458 String getPropertyPriority(String propertyName) native; |
| 1459 | 1459 |
| 1460 /** @domName CSSStyleDeclaration.getPropertyShorthand */ | 1460 /** @domName CSSStyleDeclaration.getPropertyShorthand */ |
| 1461 String getPropertyShorthand(String propertyName) native; | 1461 String getPropertyShorthand(String propertyName) native; |
| 1462 | 1462 |
| 1463 /** @domName CSSStyleDeclaration._getPropertyValue */ | 1463 /** @domName CSSStyleDeclaration._getPropertyValue */ |
| 1464 String _getPropertyValue(String propertyName) native "getPropertyValue"; | 1464 String _getPropertyValue(String propertyName) native "getPropertyValue"; |
| 1465 | 1465 |
| (...skipping 3311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 4777 return e; | 4777 return e; |
| 4778 } | 4778 } |
| 4779 | 4779 |
| 4780 /** @domName HTMLCanvasElement.height */ | 4780 /** @domName HTMLCanvasElement.height */ |
| 4781 int height; | 4781 int height; |
| 4782 | 4782 |
| 4783 /** @domName HTMLCanvasElement.width */ | 4783 /** @domName HTMLCanvasElement.width */ |
| 4784 int width; | 4784 int width; |
| 4785 | 4785 |
| 4786 /** @domName HTMLCanvasElement.toDataURL */ | 4786 /** @domName HTMLCanvasElement.toDataURL */ |
| 4787 String toDataURL(String type, [num quality]) native; | 4787 String toDataUrl(String type, [num quality]) native "toDataURL"; |
| 4788 | 4788 |
| 4789 | 4789 |
| 4790 CanvasRenderingContext getContext(String contextId) native; | 4790 CanvasRenderingContext getContext(String contextId) native; |
| 4791 CanvasRenderingContext2D get context2d => getContext('2d'); | 4791 CanvasRenderingContext2D get context2d => getContext('2d'); |
| 4792 } | 4792 } |
| 4793 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 4793 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 4794 // for details. All rights reserved. Use of this source code is governed by a | 4794 // for details. All rights reserved. Use of this source code is governed by a |
| 4795 // BSD-style license that can be found in the LICENSE file. | 4795 // BSD-style license that can be found in the LICENSE file. |
| 4796 | 4796 |
| 4797 | 4797 |
| (...skipping 833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 5631 } | 5631 } |
| 5632 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 5632 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 5633 // for details. All rights reserved. Use of this source code is governed by a | 5633 // for details. All rights reserved. Use of this source code is governed by a |
| 5634 // BSD-style license that can be found in the LICENSE file. | 5634 // BSD-style license that can be found in the LICENSE file. |
| 5635 | 5635 |
| 5636 | 5636 |
| 5637 /// @domName DOMImplementation | 5637 /// @domName DOMImplementation |
| 5638 class DOMImplementation native "*DOMImplementation" { | 5638 class DOMImplementation native "*DOMImplementation" { |
| 5639 | 5639 |
| 5640 /** @domName DOMImplementation.createCSSStyleSheet */ | 5640 /** @domName DOMImplementation.createCSSStyleSheet */ |
| 5641 CSSStyleSheet createCSSStyleSheet(String title, String media) native; | 5641 CSSStyleSheet createCssStyleSheet(String title, String media) native "createCS SStyleSheet"; |
|
Bob Nystrom
2012/11/20 00:35:10
Will "CSSStyleSheet" be renamed at some point?
blois
2012/11/20 00:44:41
Yes, I've been planning on renaming the classes as
| |
| 5642 | 5642 |
| 5643 /** @domName DOMImplementation.createDocument */ | 5643 /** @domName DOMImplementation.createDocument */ |
| 5644 Document createDocument(String namespaceURI, String qualifiedName, DocumentTyp e doctype) native; | 5644 Document createDocument(String namespaceURI, String qualifiedName, DocumentTyp e doctype) native; |
| 5645 | 5645 |
| 5646 /** @domName DOMImplementation.createDocumentType */ | 5646 /** @domName DOMImplementation.createDocumentType */ |
| 5647 DocumentType createDocumentType(String qualifiedName, String publicId, String systemId) native; | 5647 DocumentType createDocumentType(String qualifiedName, String publicId, String systemId) native; |
| 5648 | 5648 |
| 5649 /** @domName DOMImplementation.createHTMLDocument */ | 5649 /** @domName DOMImplementation.createHTMLDocument */ |
| 5650 HtmlDocument createHTMLDocument(String title) native; | 5650 HtmlDocument createHtmlDocument(String title) native "createHTMLDocument"; |
| 5651 | 5651 |
| 5652 /** @domName DOMImplementation.hasFeature */ | 5652 /** @domName DOMImplementation.hasFeature */ |
| 5653 bool hasFeature(String feature, String version) native; | 5653 bool hasFeature(String feature, String version) native; |
| 5654 } | 5654 } |
| 5655 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 5655 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 5656 // for details. All rights reserved. Use of this source code is governed by a | 5656 // for details. All rights reserved. Use of this source code is governed by a |
| 5657 // BSD-style license that can be found in the LICENSE file. | 5657 // BSD-style license that can be found in the LICENSE file. |
| 5658 | 5658 |
| 5659 | 5659 |
| 5660 /// @domName MimeType | 5660 /// @domName MimeType |
| (...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6532 /** @domName Document.webkitPointerLockElement */ | 6532 /** @domName Document.webkitPointerLockElement */ |
| 6533 Element get $dom_webkitPointerLockElement => JS("Element", "#.webkitPointerLoc kElement", this); | 6533 Element get $dom_webkitPointerLockElement => JS("Element", "#.webkitPointerLoc kElement", this); |
| 6534 | 6534 |
| 6535 /** @domName Document.webkitVisibilityState */ | 6535 /** @domName Document.webkitVisibilityState */ |
| 6536 String get $dom_webkitVisibilityState => JS("String", "#.webkitVisibilityState ", this); | 6536 String get $dom_webkitVisibilityState => JS("String", "#.webkitVisibilityState ", this); |
| 6537 | 6537 |
| 6538 /** @domName Document.caretRangeFromPoint */ | 6538 /** @domName Document.caretRangeFromPoint */ |
| 6539 Range $dom_caretRangeFromPoint(int x, int y) native "caretRangeFromPoint"; | 6539 Range $dom_caretRangeFromPoint(int x, int y) native "caretRangeFromPoint"; |
| 6540 | 6540 |
| 6541 /** @domName Document.createCDATASection */ | 6541 /** @domName Document.createCDATASection */ |
| 6542 CDATASection createCDATASection(String data) native; | 6542 CDATASection createCDataSection(String data) native "createCDATASection"; |
| 6543 | 6543 |
| 6544 /** @domName Document.createDocumentFragment */ | 6544 /** @domName Document.createDocumentFragment */ |
| 6545 DocumentFragment createDocumentFragment() native; | 6545 DocumentFragment createDocumentFragment() native; |
| 6546 | 6546 |
| 6547 /** @domName Document.createElement */ | 6547 /** @domName Document.createElement */ |
| 6548 Element $dom_createElement(String tagName) native "createElement"; | 6548 Element $dom_createElement(String tagName) native "createElement"; |
| 6549 | 6549 |
| 6550 /** @domName Document.createElementNS */ | 6550 /** @domName Document.createElementNS */ |
| 6551 Element $dom_createElementNS(String namespaceURI, String qualifiedName) native "createElementNS"; | 6551 Element $dom_createElementNS(String namespaceURI, String qualifiedName) native "createElementNS"; |
| 6552 | 6552 |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 6569 /** @domName Document.createTouchList */ | 6569 /** @domName Document.createTouchList */ |
| 6570 TouchList $dom_createTouchList() native "createTouchList"; | 6570 TouchList $dom_createTouchList() native "createTouchList"; |
| 6571 | 6571 |
| 6572 /** @domName Document.elementFromPoint */ | 6572 /** @domName Document.elementFromPoint */ |
| 6573 Element $dom_elementFromPoint(int x, int y) native "elementFromPoint"; | 6573 Element $dom_elementFromPoint(int x, int y) native "elementFromPoint"; |
| 6574 | 6574 |
| 6575 /** @domName Document.execCommand */ | 6575 /** @domName Document.execCommand */ |
| 6576 bool execCommand(String command, bool userInterface, String value) native; | 6576 bool execCommand(String command, bool userInterface, String value) native; |
| 6577 | 6577 |
| 6578 /** @domName Document.getCSSCanvasContext */ | 6578 /** @domName Document.getCSSCanvasContext */ |
| 6579 CanvasRenderingContext getCSSCanvasContext(String contextId, String name, int width, int height) native; | 6579 CanvasRenderingContext getCssCanvasContext(String contextId, String name, int width, int height) native "getCSSCanvasContext"; |
| 6580 | 6580 |
| 6581 /** @domName Document.getElementById */ | 6581 /** @domName Document.getElementById */ |
| 6582 Element $dom_getElementById(String elementId) native "getElementById"; | 6582 Element $dom_getElementById(String elementId) native "getElementById"; |
| 6583 | 6583 |
| 6584 /** @domName Document.getElementsByClassName */ | 6584 /** @domName Document.getElementsByClassName */ |
| 6585 List<Node> $dom_getElementsByClassName(String tagname) native "getElementsByCl assName"; | 6585 List<Node> $dom_getElementsByClassName(String tagname) native "getElementsByCl assName"; |
| 6586 | 6586 |
| 6587 /** @domName Document.getElementsByName */ | 6587 /** @domName Document.getElementsByName */ |
| 6588 List<Node> $dom_getElementsByName(String elementName) native "getElementsByNam e"; | 6588 List<Node> $dom_getElementsByName(String elementName) native "getElementsByNam e"; |
| 6589 | 6589 |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6809 var children = this.children; | 6809 var children = this.children; |
| 6810 children.clear(); | 6810 children.clear(); |
| 6811 children.addAll(copy); | 6811 children.addAll(copy); |
| 6812 } | 6812 } |
| 6813 | 6813 |
| 6814 Element query(String selectors) => $dom_querySelector(selectors); | 6814 Element query(String selectors) => $dom_querySelector(selectors); |
| 6815 | 6815 |
| 6816 List<Element> queryAll(String selectors) => | 6816 List<Element> queryAll(String selectors) => |
| 6817 new _FrozenElementList._wrap($dom_querySelectorAll(selectors)); | 6817 new _FrozenElementList._wrap($dom_querySelectorAll(selectors)); |
| 6818 | 6818 |
| 6819 String get innerHTML { | 6819 String get innerHtml { |
| 6820 final e = new Element.tag("div"); | 6820 final e = new Element.tag("div"); |
| 6821 e.nodes.add(this.clone(true)); | 6821 e.nodes.add(this.clone(true)); |
| 6822 return e.innerHTML; | 6822 return e.innerHtml; |
| 6823 } | 6823 } |
| 6824 | 6824 |
| 6825 String get outerHTML => innerHTML; | 6825 String get outerHtml => innerHtml; |
| 6826 | 6826 |
| 6827 // TODO(nweiz): Do we want to support some variant of innerHTML for XML and/or | 6827 // TODO(nweiz): Do we want to support some variant of innerHtml for XML and/or |
| 6828 // SVG strings? | 6828 // SVG strings? |
| 6829 void set innerHTML(String value) { | 6829 void set innerHtml(String value) { |
| 6830 this.nodes.clear(); | 6830 this.nodes.clear(); |
| 6831 | 6831 |
| 6832 final e = new Element.tag("div"); | 6832 final e = new Element.tag("div"); |
| 6833 e.innerHTML = value; | 6833 e.innerHtml = value; |
| 6834 | 6834 |
| 6835 // Copy list first since we don't want liveness during iteration. | 6835 // Copy list first since we don't want liveness during iteration. |
| 6836 List nodes = new List.from(e.nodes); | 6836 List nodes = new List.from(e.nodes); |
| 6837 this.nodes.addAll(nodes); | 6837 this.nodes.addAll(nodes); |
| 6838 } | 6838 } |
| 6839 | 6839 |
| 6840 Node _insertAdjacentNode(String where, Node node) { | 6840 Node _insertAdjacentNode(String where, Node node) { |
| 6841 switch (where.toLowerCase()) { | 6841 switch (where.toLowerCase()) { |
| 6842 case "beforebegin": return null; | 6842 case "beforebegin": return null; |
| 6843 case "afterend": return null; | 6843 case "afterend": return null; |
| 6844 case "afterbegin": | 6844 case "afterbegin": |
| 6845 var first = this.nodes.length > 0 ? this.nodes[0] : null; | 6845 var first = this.nodes.length > 0 ? this.nodes[0] : null; |
| 6846 this.insertBefore(node, first); | 6846 this.insertBefore(node, first); |
| 6847 return node; | 6847 return node; |
| 6848 case "beforeend": | 6848 case "beforeend": |
| 6849 this.nodes.add(node); | 6849 this.nodes.add(node); |
| 6850 return node; | 6850 return node; |
| 6851 default: | 6851 default: |
| 6852 throw new ArgumentError("Invalid position ${where}"); | 6852 throw new ArgumentError("Invalid position ${where}"); |
| 6853 } | 6853 } |
| 6854 } | 6854 } |
| 6855 | 6855 |
| 6856 Element insertAdjacentElement(String where, Element element) | 6856 Element insertAdjacentElement(String where, Element element) |
| 6857 => this._insertAdjacentNode(where, element); | 6857 => this._insertAdjacentNode(where, element); |
| 6858 | 6858 |
| 6859 void insertAdjacentText(String where, String text) { | 6859 void insertAdjacentText(String where, String text) { |
| 6860 this._insertAdjacentNode(where, new Text(text)); | 6860 this._insertAdjacentNode(where, new Text(text)); |
| 6861 } | 6861 } |
| 6862 | 6862 |
| 6863 void insertAdjacentHTML(String where, String text) { | 6863 void insertAdjacentHtml(String where, String text) { |
| 6864 this._insertAdjacentNode(where, new DocumentFragment.html(text)); | 6864 this._insertAdjacentNode(where, new DocumentFragment.html(text)); |
| 6865 } | 6865 } |
| 6866 | 6866 |
| 6867 void addText(String text) { | 6867 void addText(String text) { |
| 6868 this.insertAdjacentText('beforeend', text); | 6868 this.insertAdjacentText('beforeend', text); |
| 6869 } | 6869 } |
| 6870 | 6870 |
| 6871 void addHtml(String text) { | 6871 void addHtml(String text) { |
| 6872 this.insertAdjacentHTML('beforeend', text); | 6872 this.insertAdjacentHtml('beforeend', text); |
| 6873 } | 6873 } |
| 6874 | 6874 |
| 6875 // If we can come up with a semi-reasonable default value for an Element | 6875 // If we can come up with a semi-reasonable default value for an Element |
| 6876 // getter, we'll use it. In general, these return the same values as an | 6876 // getter, we'll use it. In general, these return the same values as an |
| 6877 // element that has no parent. | 6877 // element that has no parent. |
| 6878 String get contentEditable => "false"; | 6878 String get contentEditable => "false"; |
| 6879 bool get isContentEditable => false; | 6879 bool get isContentEditable => false; |
| 6880 bool get draggable => false; | 6880 bool get draggable => false; |
| 6881 bool get hidden => false; | 6881 bool get hidden => false; |
| 6882 bool get spellcheck => false; | 6882 bool get spellcheck => false; |
| (...skipping 811 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 7694 */ | 7694 */ |
| 7695 void addText(String text) { | 7695 void addText(String text) { |
| 7696 this.insertAdjacentText('beforeend', text); | 7696 this.insertAdjacentText('beforeend', text); |
| 7697 } | 7697 } |
| 7698 | 7698 |
| 7699 /** | 7699 /** |
| 7700 * Parses the specified text as HTML and adds the resulting node after the | 7700 * Parses the specified text as HTML and adds the resulting node after the |
| 7701 * last child of this. | 7701 * last child of this. |
| 7702 */ | 7702 */ |
| 7703 void addHtml(String text) { | 7703 void addHtml(String text) { |
| 7704 this.insertAdjacentHTML('beforeend', text); | 7704 this.insertAdjacentHtml('beforeend', text); |
| 7705 } | 7705 } |
| 7706 | 7706 |
| 7707 // Hooks to support custom WebComponents. | 7707 // Hooks to support custom WebComponents. |
| 7708 /** | 7708 /** |
| 7709 * Experimental support for [web components][wc]. This field stores a | 7709 * Experimental support for [web components][wc]. This field stores a |
| 7710 * reference to the component implementation. It was inspired by Mozilla's | 7710 * reference to the component implementation. It was inspired by Mozilla's |
| 7711 * [x-tags][] project. Please note: in the future it may be possible to | 7711 * [x-tags][] project. Please note: in the future it may be possible to |
| 7712 * `extend Element` from your class, in which case this field will be | 7712 * `extend Element` from your class, in which case this field will be |
| 7713 * deprecated and will simply return this [Element] object. | 7713 * deprecated and will simply return this [Element] object. |
| 7714 * | 7714 * |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 7725 _insertAdjacentText(where, text); | 7725 _insertAdjacentText(where, text); |
| 7726 } else { | 7726 } else { |
| 7727 _insertAdjacentNode(where, new Text(text)); | 7727 _insertAdjacentNode(where, new Text(text)); |
| 7728 } | 7728 } |
| 7729 } | 7729 } |
| 7730 | 7730 |
| 7731 void _insertAdjacentText(String where, String text) | 7731 void _insertAdjacentText(String where, String text) |
| 7732 native 'insertAdjacentText'; | 7732 native 'insertAdjacentText'; |
| 7733 | 7733 |
| 7734 /** @domName Element.insertAdjacentHTML */ | 7734 /** @domName Element.insertAdjacentHTML */ |
| 7735 void insertAdjacentHTML(String where, String text) { | 7735 void insertAdjacentHtml(String where, String text) { |
| 7736 if (JS('bool', '!!#.insertAdjacentHTML', this)) { | 7736 if (JS('bool', '!!#.insertAdjacentHtml', this)) { |
| 7737 _insertAdjacentHTML(where, text); | 7737 _insertAdjacentHtml(where, text); |
| 7738 } else { | 7738 } else { |
| 7739 _insertAdjacentNode(where, new DocumentFragment.html(text)); | 7739 _insertAdjacentNode(where, new DocumentFragment.html(text)); |
| 7740 } | 7740 } |
| 7741 } | 7741 } |
| 7742 | 7742 |
| 7743 void _insertAdjacentHTML(String where, String text) | 7743 void _insertAdjacentHtml(String where, String text) |
| 7744 native 'insertAdjacentHTML'; | 7744 native 'insertAdjacentHTML'; |
| 7745 | 7745 |
| 7746 /** @domName Element.insertAdjacentHTML */ | 7746 /** @domName Element.insertAdjacentHTML */ |
| 7747 Element insertAdjacentElement(String where, Element element) { | 7747 Element insertAdjacentElement(String where, Element element) { |
| 7748 if (JS('bool', '!!#.insertAdjacentElement', this)) { | 7748 if (JS('bool', '!!#.insertAdjacentElement', this)) { |
| 7749 _insertAdjacentElement(where, element); | 7749 _insertAdjacentElement(where, element); |
| 7750 } else { | 7750 } else { |
| 7751 _insertAdjacentNode(where, element); | 7751 _insertAdjacentNode(where, element); |
| 7752 } | 7752 } |
| 7753 return element; | 7753 return element; |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 7795 /** @domName HTMLElement.draggable */ | 7795 /** @domName HTMLElement.draggable */ |
| 7796 bool draggable; | 7796 bool draggable; |
| 7797 | 7797 |
| 7798 /** @domName HTMLElement.hidden */ | 7798 /** @domName HTMLElement.hidden */ |
| 7799 bool hidden; | 7799 bool hidden; |
| 7800 | 7800 |
| 7801 /** @domName HTMLElement.id */ | 7801 /** @domName HTMLElement.id */ |
| 7802 String id; | 7802 String id; |
| 7803 | 7803 |
| 7804 /** @domName HTMLElement.innerHTML */ | 7804 /** @domName HTMLElement.innerHTML */ |
| 7805 String innerHTML; | 7805 String get innerHtml => JS("String", "#.innerHTML", this); |
| 7806 | |
| 7807 /** @domName HTMLElement.innerHTML */ | |
| 7808 void set innerHtml(String value) { | |
| 7809 JS("void", "#.innerHTML = #", this, value); | |
| 7810 } | |
| 7806 | 7811 |
| 7807 /** @domName HTMLElement.isContentEditable */ | 7812 /** @domName HTMLElement.isContentEditable */ |
| 7808 final bool isContentEditable; | 7813 final bool isContentEditable; |
| 7809 | 7814 |
| 7810 /** @domName HTMLElement.lang */ | 7815 /** @domName HTMLElement.lang */ |
| 7811 String lang; | 7816 String lang; |
| 7812 | 7817 |
| 7813 /** @domName HTMLElement.outerHTML */ | 7818 /** @domName HTMLElement.outerHTML */ |
| 7814 final String outerHTML; | 7819 String get outerHtml => JS("String", "#.outerHTML", this); |
| 7815 | 7820 |
| 7816 /** @domName HTMLElement.spellcheck */ | 7821 /** @domName HTMLElement.spellcheck */ |
| 7817 bool spellcheck; | 7822 bool spellcheck; |
| 7818 | 7823 |
| 7819 /** @domName HTMLElement.tabIndex */ | 7824 /** @domName HTMLElement.tabIndex */ |
| 7820 int tabIndex; | 7825 int tabIndex; |
| 7821 | 7826 |
| 7822 /** @domName HTMLElement.title */ | 7827 /** @domName HTMLElement.title */ |
| 7823 String title; | 7828 String title; |
| 7824 | 7829 |
| (...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 7993 String parentTag = 'div'; | 7998 String parentTag = 'div'; |
| 7994 String tag; | 7999 String tag; |
| 7995 final match = _START_TAG_REGEXP.firstMatch(html); | 8000 final match = _START_TAG_REGEXP.firstMatch(html); |
| 7996 if (match != null) { | 8001 if (match != null) { |
| 7997 tag = match.group(1).toLowerCase(); | 8002 tag = match.group(1).toLowerCase(); |
| 7998 if (_CUSTOM_PARENT_TAG_MAP.containsKey(tag)) { | 8003 if (_CUSTOM_PARENT_TAG_MAP.containsKey(tag)) { |
| 7999 parentTag = _CUSTOM_PARENT_TAG_MAP[tag]; | 8004 parentTag = _CUSTOM_PARENT_TAG_MAP[tag]; |
| 8000 } | 8005 } |
| 8001 } | 8006 } |
| 8002 final Element temp = new Element.tag(parentTag); | 8007 final Element temp = new Element.tag(parentTag); |
| 8003 temp.innerHTML = html; | 8008 temp.innerHtml = html; |
| 8004 | 8009 |
| 8005 Element element; | 8010 Element element; |
| 8006 if (temp.children.length == 1) { | 8011 if (temp.children.length == 1) { |
| 8007 element = temp.children[0]; | 8012 element = temp.children[0]; |
| 8008 } else if (parentTag == 'html' && temp.children.length == 2) { | 8013 } else if (parentTag == 'html' && temp.children.length == 2) { |
| 8009 // Work around for edge case in WebKit and possibly other browsers where | 8014 // Work around for edge case in WebKit and possibly other browsers where |
| 8010 // both body and head elements are created even though the inner html | 8015 // both body and head elements are created even though the inner html |
| 8011 // only contains a head or body element. | 8016 // only contains a head or body element. |
| 8012 element = temp.children[tag == 'head' ? 0 : 1]; | 8017 element = temp.children[tag == 'head' ? 0 : 1]; |
| 8013 } else { | 8018 } else { |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 8253 /** @domName Entry.getParent */ | 8258 /** @domName Entry.getParent */ |
| 8254 void getParent([EntryCallback successCallback, ErrorCallback errorCallback]) n ative; | 8259 void getParent([EntryCallback successCallback, ErrorCallback errorCallback]) n ative; |
| 8255 | 8260 |
| 8256 /** @domName Entry.moveTo */ | 8261 /** @domName Entry.moveTo */ |
| 8257 void moveTo(DirectoryEntry parent, [String name, EntryCallback successCallback , ErrorCallback errorCallback]) native; | 8262 void moveTo(DirectoryEntry parent, [String name, EntryCallback successCallback , ErrorCallback errorCallback]) native; |
| 8258 | 8263 |
| 8259 /** @domName Entry.remove */ | 8264 /** @domName Entry.remove */ |
| 8260 void remove(VoidCallback successCallback, [ErrorCallback errorCallback]) nativ e; | 8265 void remove(VoidCallback successCallback, [ErrorCallback errorCallback]) nativ e; |
| 8261 | 8266 |
| 8262 /** @domName Entry.toURL */ | 8267 /** @domName Entry.toURL */ |
| 8263 String toURL() native; | 8268 String toUrl() native "toURL"; |
| 8264 } | 8269 } |
| 8265 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 8270 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 8266 // for details. All rights reserved. Use of this source code is governed by a | 8271 // for details. All rights reserved. Use of this source code is governed by a |
| 8267 // BSD-style license that can be found in the LICENSE file. | 8272 // BSD-style license that can be found in the LICENSE file. |
| 8268 | 8273 |
| 8269 // WARNING: Do not edit - generated code. | 8274 // WARNING: Do not edit - generated code. |
| 8270 | 8275 |
| 8271 | 8276 |
| 8272 typedef void EntryCallback(Entry entry); | 8277 typedef void EntryCallback(Entry entry); |
| 8273 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 8278 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| (...skipping 28 matching lines...) Expand all Loading... | |
| 8302 /** @domName EntrySync.getParent */ | 8307 /** @domName EntrySync.getParent */ |
| 8303 EntrySync getParent() native; | 8308 EntrySync getParent() native; |
| 8304 | 8309 |
| 8305 /** @domName EntrySync.moveTo */ | 8310 /** @domName EntrySync.moveTo */ |
| 8306 EntrySync moveTo(DirectoryEntrySync parent, String name) native; | 8311 EntrySync moveTo(DirectoryEntrySync parent, String name) native; |
| 8307 | 8312 |
| 8308 /** @domName EntrySync.remove */ | 8313 /** @domName EntrySync.remove */ |
| 8309 void remove() native; | 8314 void remove() native; |
| 8310 | 8315 |
| 8311 /** @domName EntrySync.toURL */ | 8316 /** @domName EntrySync.toURL */ |
| 8312 String toURL() native; | 8317 String toUrl() native "toURL"; |
| 8313 } | 8318 } |
| 8314 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 8319 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 8315 // for details. All rights reserved. Use of this source code is governed by a | 8320 // for details. All rights reserved. Use of this source code is governed by a |
| 8316 // BSD-style license that can be found in the LICENSE file. | 8321 // BSD-style license that can be found in the LICENSE file. |
| 8317 | 8322 |
| 8318 // WARNING: Do not edit - generated code. | 8323 // WARNING: Do not edit - generated code. |
| 8319 | 8324 |
| 8320 | 8325 |
| 8321 typedef void ErrorCallback(FileError error); | 8326 typedef void ErrorCallback(FileError error); |
| 8322 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 8327 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 8480 */ | 8485 */ |
| 8481 EventSourceEvents get on => | 8486 EventSourceEvents get on => |
| 8482 new EventSourceEvents(this); | 8487 new EventSourceEvents(this); |
| 8483 | 8488 |
| 8484 static const int CLOSED = 2; | 8489 static const int CLOSED = 2; |
| 8485 | 8490 |
| 8486 static const int CONNECTING = 0; | 8491 static const int CONNECTING = 0; |
| 8487 | 8492 |
| 8488 static const int OPEN = 1; | 8493 static const int OPEN = 1; |
| 8489 | 8494 |
| 8490 /** @domName EventSource.URL */ | |
| 8491 final String URL; | |
| 8492 | |
| 8493 /** @domName EventSource.readyState */ | 8495 /** @domName EventSource.readyState */ |
| 8494 final int readyState; | 8496 final int readyState; |
| 8495 | 8497 |
| 8496 /** @domName EventSource.url */ | 8498 /** @domName EventSource.url */ |
| 8497 final String url; | 8499 final String url; |
| 8498 | 8500 |
| 8499 /** @domName EventSource.addEventListener */ | 8501 /** @domName EventSource.addEventListener */ |
| 8500 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu re]) native "addEventListener"; | 8502 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu re]) native "addEventListener"; |
| 8501 | 8503 |
| 8502 /** @domName EventSource.close */ | 8504 /** @domName EventSource.close */ |
| (...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 8796 /** @domName FileReader.dispatchEvent */ | 8798 /** @domName FileReader.dispatchEvent */ |
| 8797 bool $dom_dispatchEvent(Event evt) native "dispatchEvent"; | 8799 bool $dom_dispatchEvent(Event evt) native "dispatchEvent"; |
| 8798 | 8800 |
| 8799 /** @domName FileReader.readAsArrayBuffer */ | 8801 /** @domName FileReader.readAsArrayBuffer */ |
| 8800 void readAsArrayBuffer(Blob blob) native; | 8802 void readAsArrayBuffer(Blob blob) native; |
| 8801 | 8803 |
| 8802 /** @domName FileReader.readAsBinaryString */ | 8804 /** @domName FileReader.readAsBinaryString */ |
| 8803 void readAsBinaryString(Blob blob) native; | 8805 void readAsBinaryString(Blob blob) native; |
| 8804 | 8806 |
| 8805 /** @domName FileReader.readAsDataURL */ | 8807 /** @domName FileReader.readAsDataURL */ |
| 8806 void readAsDataURL(Blob blob) native; | 8808 void readAsDataUrl(Blob blob) native "readAsDataURL"; |
| 8807 | 8809 |
| 8808 /** @domName FileReader.readAsText */ | 8810 /** @domName FileReader.readAsText */ |
| 8809 void readAsText(Blob blob, [String encoding]) native; | 8811 void readAsText(Blob blob, [String encoding]) native; |
| 8810 | 8812 |
| 8811 /** @domName FileReader.removeEventListener */ | 8813 /** @domName FileReader.removeEventListener */ |
| 8812 void $dom_removeEventListener(String type, EventListener listener, [bool useCa pture]) native "removeEventListener"; | 8814 void $dom_removeEventListener(String type, EventListener listener, [bool useCa pture]) native "removeEventListener"; |
| 8813 } | 8815 } |
| 8814 | 8816 |
| 8815 class FileReaderEvents extends Events { | 8817 class FileReaderEvents extends Events { |
| 8816 FileReaderEvents(EventTarget _ptr) : super(_ptr); | 8818 FileReaderEvents(EventTarget _ptr) : super(_ptr); |
| (...skipping 20 matching lines...) Expand all Loading... | |
| 8837 | 8839 |
| 8838 factory FileReaderSync() => _FileReaderSyncFactoryProvider.createFileReaderSyn c(); | 8840 factory FileReaderSync() => _FileReaderSyncFactoryProvider.createFileReaderSyn c(); |
| 8839 | 8841 |
| 8840 /** @domName FileReaderSync.readAsArrayBuffer */ | 8842 /** @domName FileReaderSync.readAsArrayBuffer */ |
| 8841 ArrayBuffer readAsArrayBuffer(Blob blob) native; | 8843 ArrayBuffer readAsArrayBuffer(Blob blob) native; |
| 8842 | 8844 |
| 8843 /** @domName FileReaderSync.readAsBinaryString */ | 8845 /** @domName FileReaderSync.readAsBinaryString */ |
| 8844 String readAsBinaryString(Blob blob) native; | 8846 String readAsBinaryString(Blob blob) native; |
| 8845 | 8847 |
| 8846 /** @domName FileReaderSync.readAsDataURL */ | 8848 /** @domName FileReaderSync.readAsDataURL */ |
| 8847 String readAsDataURL(Blob blob) native; | 8849 String readAsDataUrl(Blob blob) native "readAsDataURL"; |
| 8848 | 8850 |
| 8849 /** @domName FileReaderSync.readAsText */ | 8851 /** @domName FileReaderSync.readAsText */ |
| 8850 String readAsText(Blob blob, [String encoding]) native; | 8852 String readAsText(Blob blob, [String encoding]) native; |
| 8851 } | 8853 } |
| 8852 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 8854 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 8853 // for details. All rights reserved. Use of this source code is governed by a | 8855 // for details. All rights reserved. Use of this source code is governed by a |
| 8854 // BSD-style license that can be found in the LICENSE file. | 8856 // BSD-style license that can be found in the LICENSE file. |
| 8855 | 8857 |
| 8856 // WARNING: Do not edit - generated code. | 8858 // WARNING: Do not edit - generated code. |
| 8857 | 8859 |
| (...skipping 817 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 9675 } | 9677 } |
| 9676 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 9678 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 9677 // for details. All rights reserved. Use of this source code is governed by a | 9679 // for details. All rights reserved. Use of this source code is governed by a |
| 9678 // BSD-style license that can be found in the LICENSE file. | 9680 // BSD-style license that can be found in the LICENSE file. |
| 9679 | 9681 |
| 9680 | 9682 |
| 9681 /// @domName HashChangeEvent | 9683 /// @domName HashChangeEvent |
| 9682 class HashChangeEvent extends Event native "*HashChangeEvent" { | 9684 class HashChangeEvent extends Event native "*HashChangeEvent" { |
| 9683 | 9685 |
| 9684 /** @domName HashChangeEvent.newURL */ | 9686 /** @domName HashChangeEvent.newURL */ |
| 9685 final String newURL; | 9687 String get newUrl => JS("String", "#.newURL", this); |
| 9686 | 9688 |
| 9687 /** @domName HashChangeEvent.oldURL */ | 9689 /** @domName HashChangeEvent.oldURL */ |
| 9688 final String oldURL; | 9690 String get oldUrl => JS("String", "#.oldURL", this); |
| 9689 | 9691 |
| 9690 /** @domName HashChangeEvent.initHashChangeEvent */ | 9692 /** @domName HashChangeEvent.initHashChangeEvent */ |
| 9691 void initHashChangeEvent(String type, bool canBubble, bool cancelable, String oldURL, String newURL) native; | 9693 void initHashChangeEvent(String type, bool canBubble, bool cancelable, String oldURL, String newURL) native; |
| 9692 } | 9694 } |
| 9693 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 9695 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 9694 // for details. All rights reserved. Use of this source code is governed by a | 9696 // for details. All rights reserved. Use of this source code is governed by a |
| 9695 // BSD-style license that can be found in the LICENSE file. | 9697 // BSD-style license that can be found in the LICENSE file. |
| 9696 | 9698 |
| 9697 | 9699 |
| 9698 /// @domName HTMLHeadElement | 9700 /// @domName HTMLHeadElement |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 9857 /** @domName XMLHttpRequest.response */ | 9859 /** @domName XMLHttpRequest.response */ |
| 9858 final Object response; | 9860 final Object response; |
| 9859 | 9861 |
| 9860 /** @domName XMLHttpRequest.responseText */ | 9862 /** @domName XMLHttpRequest.responseText */ |
| 9861 final String responseText; | 9863 final String responseText; |
| 9862 | 9864 |
| 9863 /** @domName XMLHttpRequest.responseType */ | 9865 /** @domName XMLHttpRequest.responseType */ |
| 9864 String responseType; | 9866 String responseType; |
| 9865 | 9867 |
| 9866 /** @domName XMLHttpRequest.responseXML */ | 9868 /** @domName XMLHttpRequest.responseXML */ |
| 9867 final Document responseXML; | 9869 Document get responseXml => JS("Document", "#.responseXML", this); |
| 9868 | 9870 |
| 9869 /** @domName XMLHttpRequest.status */ | 9871 /** @domName XMLHttpRequest.status */ |
| 9870 final int status; | 9872 final int status; |
| 9871 | 9873 |
| 9872 /** @domName XMLHttpRequest.statusText */ | 9874 /** @domName XMLHttpRequest.statusText */ |
| 9873 final String statusText; | 9875 final String statusText; |
| 9874 | 9876 |
| 9875 /** @domName XMLHttpRequest.upload */ | 9877 /** @domName XMLHttpRequest.upload */ |
| 9876 final HttpRequestUpload upload; | 9878 final HttpRequestUpload upload; |
| 9877 | 9879 |
| (...skipping 2288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 12166 /** @domName Window.find */ | 12168 /** @domName Window.find */ |
| 12167 bool find(String string, bool caseSensitive, bool backwards, bool wrap, bool w holeWord, bool searchInFrames, bool showDialog) native; | 12169 bool find(String string, bool caseSensitive, bool backwards, bool wrap, bool w holeWord, bool searchInFrames, bool showDialog) native; |
| 12168 | 12170 |
| 12169 /** @domName Window.focus */ | 12171 /** @domName Window.focus */ |
| 12170 void focus() native; | 12172 void focus() native; |
| 12171 | 12173 |
| 12172 /** @domName Window.getComputedStyle */ | 12174 /** @domName Window.getComputedStyle */ |
| 12173 CSSStyleDeclaration $dom_getComputedStyle(Element element, String pseudoElemen t) native "getComputedStyle"; | 12175 CSSStyleDeclaration $dom_getComputedStyle(Element element, String pseudoElemen t) native "getComputedStyle"; |
| 12174 | 12176 |
| 12175 /** @domName Window.getMatchedCSSRules */ | 12177 /** @domName Window.getMatchedCSSRules */ |
| 12176 List<CSSRule> getMatchedCSSRules(Element element, String pseudoElement) native ; | 12178 List<CSSRule> getMatchedCssRules(Element element, String pseudoElement) native "getMatchedCSSRules"; |
| 12177 | 12179 |
| 12178 /** @domName Window.getSelection */ | 12180 /** @domName Window.getSelection */ |
| 12179 DOMSelection getSelection() native; | 12181 DOMSelection getSelection() native; |
| 12180 | 12182 |
| 12181 /** @domName Window.matchMedia */ | 12183 /** @domName Window.matchMedia */ |
| 12182 MediaQueryList matchMedia(String query) native; | 12184 MediaQueryList matchMedia(String query) native; |
| 12183 | 12185 |
| 12184 /** @domName Window.moveBy */ | 12186 /** @domName Window.moveBy */ |
| 12185 void moveBy(num x, num y) native; | 12187 void moveBy(num x, num y) native; |
| 12186 | 12188 |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 12247 /** @domName Window.webkitConvertPointFromNodeToPage */ | 12249 /** @domName Window.webkitConvertPointFromNodeToPage */ |
| 12248 Point webkitConvertPointFromNodeToPage(Node node, Point p) native; | 12250 Point webkitConvertPointFromNodeToPage(Node node, Point p) native; |
| 12249 | 12251 |
| 12250 /** @domName Window.webkitConvertPointFromPageToNode */ | 12252 /** @domName Window.webkitConvertPointFromPageToNode */ |
| 12251 Point webkitConvertPointFromPageToNode(Node node, Point p) native; | 12253 Point webkitConvertPointFromPageToNode(Node node, Point p) native; |
| 12252 | 12254 |
| 12253 /** @domName DOMWindow.webkitRequestFileSystem */ | 12255 /** @domName DOMWindow.webkitRequestFileSystem */ |
| 12254 void webkitRequestFileSystem(int type, int size, FileSystemCallback successCal lback, [ErrorCallback errorCallback]) native; | 12256 void webkitRequestFileSystem(int type, int size, FileSystemCallback successCal lback, [ErrorCallback errorCallback]) native; |
| 12255 | 12257 |
| 12256 /** @domName DOMWindow.webkitResolveLocalFileSystemURL */ | 12258 /** @domName DOMWindow.webkitResolveLocalFileSystemURL */ |
| 12257 void webkitResolveLocalFileSystemURL(String url, EntryCallback successCallback , [ErrorCallback errorCallback]) native; | 12259 void webkitResolveLocalFileSystemUrl(String url, EntryCallback successCallback , [ErrorCallback errorCallback]) native "webkitResolveLocalFileSystemURL"; |
| 12258 | 12260 |
| 12259 } | 12261 } |
| 12260 | 12262 |
| 12261 class LocalWindowEvents extends Events { | 12263 class LocalWindowEvents extends Events { |
| 12262 LocalWindowEvents(EventTarget _ptr) : super(_ptr); | 12264 LocalWindowEvents(EventTarget _ptr) : super(_ptr); |
| 12263 | 12265 |
| 12264 EventListenerList get abort => this['abort']; | 12266 EventListenerList get abort => this['abort']; |
| 12265 | 12267 |
| 12266 EventListenerList get beforeUnload => this['beforeunload']; | 12268 EventListenerList get beforeUnload => this['beforeunload']; |
| 12267 | 12269 |
| (...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 12788 } | 12790 } |
| 12789 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 12791 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 12790 // for details. All rights reserved. Use of this source code is governed by a | 12792 // for details. All rights reserved. Use of this source code is governed by a |
| 12791 // BSD-style license that can be found in the LICENSE file. | 12793 // BSD-style license that can be found in the LICENSE file. |
| 12792 | 12794 |
| 12793 | 12795 |
| 12794 /// @domName MediaKeyEvent | 12796 /// @domName MediaKeyEvent |
| 12795 class MediaKeyEvent extends Event native "*MediaKeyEvent" { | 12797 class MediaKeyEvent extends Event native "*MediaKeyEvent" { |
| 12796 | 12798 |
| 12797 /** @domName MediaKeyEvent.defaultURL */ | 12799 /** @domName MediaKeyEvent.defaultURL */ |
| 12798 final String defaultURL; | 12800 String get defaultUrl => JS("String", "#.defaultURL", this); |
| 12799 | 12801 |
| 12800 /** @domName MediaKeyEvent.errorCode */ | 12802 /** @domName MediaKeyEvent.errorCode */ |
| 12801 final MediaKeyError errorCode; | 12803 final MediaKeyError errorCode; |
| 12802 | 12804 |
| 12803 /** @domName MediaKeyEvent.initData */ | 12805 /** @domName MediaKeyEvent.initData */ |
| 12804 final Uint8Array initData; | 12806 final Uint8Array initData; |
| 12805 | 12807 |
| 12806 /** @domName MediaKeyEvent.keySystem */ | 12808 /** @domName MediaKeyEvent.keySystem */ |
| 12807 final String keySystem; | 12809 final String keySystem; |
| 12808 | 12810 |
| (...skipping 1395 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 14204 // BSD-style license that can be found in the LICENSE file. | 14206 // BSD-style license that can be found in the LICENSE file. |
| 14205 | 14207 |
| 14206 | 14208 |
| 14207 /// @domName NotificationCenter | 14209 /// @domName NotificationCenter |
| 14208 class NotificationCenter native "*NotificationCenter" { | 14210 class NotificationCenter native "*NotificationCenter" { |
| 14209 | 14211 |
| 14210 /** @domName NotificationCenter.checkPermission */ | 14212 /** @domName NotificationCenter.checkPermission */ |
| 14211 int checkPermission() native; | 14213 int checkPermission() native; |
| 14212 | 14214 |
| 14213 /** @domName NotificationCenter.createHTMLNotification */ | 14215 /** @domName NotificationCenter.createHTMLNotification */ |
| 14214 Notification createHTMLNotification(String url) native; | 14216 Notification createHtmlNotification(String url) native "createHTMLNotification "; |
| 14215 | 14217 |
| 14216 /** @domName NotificationCenter.createNotification */ | 14218 /** @domName NotificationCenter.createNotification */ |
| 14217 Notification createNotification(String iconUrl, String title, String body) nat ive; | 14219 Notification createNotification(String iconUrl, String title, String body) nat ive; |
| 14218 | 14220 |
| 14219 /** @domName NotificationCenter.requestPermission */ | 14221 /** @domName NotificationCenter.requestPermission */ |
| 14220 void requestPermission(VoidCallback callback) native; | 14222 void requestPermission(VoidCallback callback) native; |
| 14221 } | 14223 } |
| 14222 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 14224 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 14223 // for details. All rights reserved. Use of this source code is governed by a | 14225 // for details. All rights reserved. Use of this source code is governed by a |
| 14224 // BSD-style license that can be found in the LICENSE file. | 14226 // BSD-style license that can be found in the LICENSE file. |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 14257 // for details. All rights reserved. Use of this source code is governed by a | 14259 // for details. All rights reserved. Use of this source code is governed by a |
| 14258 // BSD-style license that can be found in the LICENSE file. | 14260 // BSD-style license that can be found in the LICENSE file. |
| 14259 | 14261 |
| 14260 | 14262 |
| 14261 /// @domName OESVertexArrayObject | 14263 /// @domName OESVertexArrayObject |
| 14262 class OESVertexArrayObject native "*OESVertexArrayObject" { | 14264 class OESVertexArrayObject native "*OESVertexArrayObject" { |
| 14263 | 14265 |
| 14264 static const int VERTEX_ARRAY_BINDING_OES = 0x85B5; | 14266 static const int VERTEX_ARRAY_BINDING_OES = 0x85B5; |
| 14265 | 14267 |
| 14266 /** @domName OESVertexArrayObject.bindVertexArrayOES */ | 14268 /** @domName OESVertexArrayObject.bindVertexArrayOES */ |
| 14267 void bindVertexArrayOES(WebGLVertexArrayObjectOES arrayObject) native; | 14269 void bindVertexArrayOes(WebGLVertexArrayObjectOES arrayObject) native "bindVer texArrayOES"; |
|
Bob Nystrom
2012/11/20 00:35:10
Is "OES" here for "OpenGL ES"? If so, seems kind o
blois
2012/11/20 00:44:41
Done.
| |
| 14268 | 14270 |
| 14269 /** @domName OESVertexArrayObject.createVertexArrayOES */ | 14271 /** @domName OESVertexArrayObject.createVertexArrayOES */ |
| 14270 WebGLVertexArrayObjectOES createVertexArrayOES() native; | 14272 WebGLVertexArrayObjectOES createVertexArrayOes() native "createVertexArrayOES" ; |
| 14271 | 14273 |
| 14272 /** @domName OESVertexArrayObject.deleteVertexArrayOES */ | 14274 /** @domName OESVertexArrayObject.deleteVertexArrayOES */ |
| 14273 void deleteVertexArrayOES(WebGLVertexArrayObjectOES arrayObject) native; | 14275 void deleteVertexArrayOes(WebGLVertexArrayObjectOES arrayObject) native "delet eVertexArrayOES"; |
| 14274 | 14276 |
| 14275 /** @domName OESVertexArrayObject.isVertexArrayOES */ | 14277 /** @domName OESVertexArrayObject.isVertexArrayOES */ |
| 14276 bool isVertexArrayOES(WebGLVertexArrayObjectOES arrayObject) native; | 14278 bool isVertexArrayOes(WebGLVertexArrayObjectOES arrayObject) native "isVertexA rrayOES"; |
| 14277 } | 14279 } |
| 14278 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 14280 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 14279 // for details. All rights reserved. Use of this source code is governed by a | 14281 // for details. All rights reserved. Use of this source code is governed by a |
| 14280 // BSD-style license that can be found in the LICENSE file. | 14282 // BSD-style license that can be found in the LICENSE file. |
| 14281 | 14283 |
| 14282 | 14284 |
| 14283 /// @domName HTMLOListElement | 14285 /// @domName HTMLOListElement |
| 14284 class OListElement extends Element implements Element native "*HTMLOListElement" { | 14286 class OListElement extends Element implements Element native "*HTMLOListElement" { |
| 14285 | 14287 |
| 14286 factory OListElement() => document.$dom_createElement("ol"); | 14288 factory OListElement() => document.$dom_createElement("ol"); |
| (...skipping 1678 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 15965 } | 15967 } |
| 15966 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 15968 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 15967 // for details. All rights reserved. Use of this source code is governed by a | 15969 // for details. All rights reserved. Use of this source code is governed by a |
| 15968 // BSD-style license that can be found in the LICENSE file. | 15970 // BSD-style license that can be found in the LICENSE file. |
| 15969 | 15971 |
| 15970 | 15972 |
| 15971 /// @domName ScriptProfileNode | 15973 /// @domName ScriptProfileNode |
| 15972 class ScriptProfileNode native "*ScriptProfileNode" { | 15974 class ScriptProfileNode native "*ScriptProfileNode" { |
| 15973 | 15975 |
| 15974 /** @domName ScriptProfileNode.callUID */ | 15976 /** @domName ScriptProfileNode.callUID */ |
| 15975 final int callUID; | 15977 int get callUid => JS("int", "#.callUID", this); |
| 15976 | 15978 |
| 15977 /** @domName ScriptProfileNode.functionName */ | 15979 /** @domName ScriptProfileNode.functionName */ |
| 15978 final String functionName; | 15980 final String functionName; |
| 15979 | 15981 |
| 15980 /** @domName ScriptProfileNode.lineNumber */ | 15982 /** @domName ScriptProfileNode.lineNumber */ |
| 15981 final int lineNumber; | 15983 final int lineNumber; |
| 15982 | 15984 |
| 15983 /** @domName ScriptProfileNode.numberOfCalls */ | 15985 /** @domName ScriptProfileNode.numberOfCalls */ |
| 15984 final int numberOfCalls; | 15986 final int numberOfCalls; |
| 15985 | 15987 |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 16118 | 16120 |
| 16119 factory ShadowRoot(Element host) => _ShadowRootFactoryProvider.createShadowRoo t(host); | 16121 factory ShadowRoot(Element host) => _ShadowRootFactoryProvider.createShadowRoo t(host); |
| 16120 | 16122 |
| 16121 /** @domName ShadowRoot.activeElement */ | 16123 /** @domName ShadowRoot.activeElement */ |
| 16122 final Element activeElement; | 16124 final Element activeElement; |
| 16123 | 16125 |
| 16124 /** @domName ShadowRoot.applyAuthorStyles */ | 16126 /** @domName ShadowRoot.applyAuthorStyles */ |
| 16125 bool applyAuthorStyles; | 16127 bool applyAuthorStyles; |
| 16126 | 16128 |
| 16127 /** @domName ShadowRoot.innerHTML */ | 16129 /** @domName ShadowRoot.innerHTML */ |
| 16128 String innerHTML; | 16130 String get innerHtml => JS("String", "#.innerHTML", this); |
| 16131 | |
| 16132 /** @domName ShadowRoot.innerHTML */ | |
| 16133 void set innerHtml(String value) { | |
| 16134 JS("void", "#.innerHTML = #", this, value); | |
| 16135 } | |
| 16129 | 16136 |
| 16130 /** @domName ShadowRoot.resetStyleInheritance */ | 16137 /** @domName ShadowRoot.resetStyleInheritance */ |
| 16131 bool resetStyleInheritance; | 16138 bool resetStyleInheritance; |
| 16132 | 16139 |
| 16133 /** @domName ShadowRoot.cloneNode */ | 16140 /** @domName ShadowRoot.cloneNode */ |
| 16134 Node clone(bool deep) native "cloneNode"; | 16141 Node clone(bool deep) native "cloneNode"; |
| 16135 | 16142 |
| 16136 /** @domName ShadowRoot.getElementById */ | 16143 /** @domName ShadowRoot.getElementById */ |
| 16137 Element $dom_getElementById(String elementId) native "getElementById"; | 16144 Element $dom_getElementById(String elementId) native "getElementById"; |
| 16138 | 16145 |
| (...skipping 1226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 17365 /** @domName TextTrackCue.vertical */ | 17372 /** @domName TextTrackCue.vertical */ |
| 17366 String vertical; | 17373 String vertical; |
| 17367 | 17374 |
| 17368 /** @domName TextTrackCue.addEventListener */ | 17375 /** @domName TextTrackCue.addEventListener */ |
| 17369 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu re]) native "addEventListener"; | 17376 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu re]) native "addEventListener"; |
| 17370 | 17377 |
| 17371 /** @domName TextTrackCue.dispatchEvent */ | 17378 /** @domName TextTrackCue.dispatchEvent */ |
| 17372 bool $dom_dispatchEvent(Event evt) native "dispatchEvent"; | 17379 bool $dom_dispatchEvent(Event evt) native "dispatchEvent"; |
| 17373 | 17380 |
| 17374 /** @domName TextTrackCue.getCueAsHTML */ | 17381 /** @domName TextTrackCue.getCueAsHTML */ |
| 17375 DocumentFragment getCueAsHTML() native; | 17382 DocumentFragment getCueAsHtml() native "getCueAsHTML"; |
| 17376 | 17383 |
| 17377 /** @domName TextTrackCue.removeEventListener */ | 17384 /** @domName TextTrackCue.removeEventListener */ |
| 17378 void $dom_removeEventListener(String type, EventListener listener, [bool useCa pture]) native "removeEventListener"; | 17385 void $dom_removeEventListener(String type, EventListener listener, [bool useCa pture]) native "removeEventListener"; |
| 17379 } | 17386 } |
| 17380 | 17387 |
| 17381 class TextTrackCueEvents extends Events { | 17388 class TextTrackCueEvents extends Events { |
| 17382 TextTrackCueEvents(EventTarget _ptr) : super(_ptr); | 17389 TextTrackCueEvents(EventTarget _ptr) : super(_ptr); |
| 17383 | 17390 |
| 17384 EventListenerList get enter => this['enter']; | 17391 EventListenerList get enter => this['enter']; |
| 17385 | 17392 |
| (...skipping 2469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 19855 | 19862 |
| 19856 static const int CLOSED = 3; | 19863 static const int CLOSED = 3; |
| 19857 | 19864 |
| 19858 static const int CLOSING = 2; | 19865 static const int CLOSING = 2; |
| 19859 | 19866 |
| 19860 static const int CONNECTING = 0; | 19867 static const int CONNECTING = 0; |
| 19861 | 19868 |
| 19862 static const int OPEN = 1; | 19869 static const int OPEN = 1; |
| 19863 | 19870 |
| 19864 /** @domName WebSocket.URL */ | 19871 /** @domName WebSocket.URL */ |
| 19865 final String URL; | 19872 String get Url => JS("String", "#.URL", this); |
| 19866 | 19873 |
| 19867 /** @domName WebSocket.binaryType */ | 19874 /** @domName WebSocket.binaryType */ |
| 19868 String binaryType; | 19875 String binaryType; |
| 19869 | 19876 |
| 19870 /** @domName WebSocket.bufferedAmount */ | 19877 /** @domName WebSocket.bufferedAmount */ |
| 19871 final int bufferedAmount; | 19878 final int bufferedAmount; |
| 19872 | 19879 |
| 19873 /** @domName WebSocket.extensions */ | 19880 /** @domName WebSocket.extensions */ |
| 19874 final String extensions; | 19881 final String extensions; |
| 19875 | 19882 |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 20105 /** @domName WorkerContext.setTimeout */ | 20112 /** @domName WorkerContext.setTimeout */ |
| 20106 int setTimeout(TimeoutHandler handler, int timeout) native; | 20113 int setTimeout(TimeoutHandler handler, int timeout) native; |
| 20107 | 20114 |
| 20108 /** @domName WorkerContext.webkitRequestFileSystem */ | 20115 /** @domName WorkerContext.webkitRequestFileSystem */ |
| 20109 void webkitRequestFileSystem(int type, int size, [FileSystemCallback successCa llback, ErrorCallback errorCallback]) native; | 20116 void webkitRequestFileSystem(int type, int size, [FileSystemCallback successCa llback, ErrorCallback errorCallback]) native; |
| 20110 | 20117 |
| 20111 /** @domName WorkerContext.webkitRequestFileSystemSync */ | 20118 /** @domName WorkerContext.webkitRequestFileSystemSync */ |
| 20112 DOMFileSystemSync webkitRequestFileSystemSync(int type, int size) native; | 20119 DOMFileSystemSync webkitRequestFileSystemSync(int type, int size) native; |
| 20113 | 20120 |
| 20114 /** @domName WorkerContext.webkitResolveLocalFileSystemSyncURL */ | 20121 /** @domName WorkerContext.webkitResolveLocalFileSystemSyncURL */ |
| 20115 EntrySync webkitResolveLocalFileSystemSyncURL(String url) native; | 20122 EntrySync webkitResolveLocalFileSystemSyncUrl(String url) native "webkitResolv eLocalFileSystemSyncURL"; |
| 20116 | 20123 |
| 20117 /** @domName WorkerContext.webkitResolveLocalFileSystemURL */ | 20124 /** @domName WorkerContext.webkitResolveLocalFileSystemURL */ |
| 20118 void webkitResolveLocalFileSystemURL(String url, EntryCallback successCallback , [ErrorCallback errorCallback]) native; | 20125 void webkitResolveLocalFileSystemUrl(String url, EntryCallback successCallback , [ErrorCallback errorCallback]) native "webkitResolveLocalFileSystemURL"; |
| 20119 } | 20126 } |
| 20120 | 20127 |
| 20121 class WorkerContextEvents extends Events { | 20128 class WorkerContextEvents extends Events { |
| 20122 WorkerContextEvents(EventTarget _ptr) : super(_ptr); | 20129 WorkerContextEvents(EventTarget _ptr) : super(_ptr); |
| 20123 | 20130 |
| 20124 EventListenerList get error => this['error']; | 20131 EventListenerList get error => this['error']; |
| 20125 } | 20132 } |
| 20126 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 20133 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 20127 // for details. All rights reserved. Use of this source code is governed by a | 20134 // for details. All rights reserved. Use of this source code is governed by a |
| 20128 // BSD-style license that can be found in the LICENSE file. | 20135 // BSD-style license that can be found in the LICENSE file. |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 20250 } | 20257 } |
| 20251 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 20258 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 20252 // for details. All rights reserved. Use of this source code is governed by a | 20259 // for details. All rights reserved. Use of this source code is governed by a |
| 20253 // BSD-style license that can be found in the LICENSE file. | 20260 // BSD-style license that can be found in the LICENSE file. |
| 20254 | 20261 |
| 20255 | 20262 |
| 20256 /// @domName XPathNSResolver | 20263 /// @domName XPathNSResolver |
| 20257 class XPathNSResolver native "*XPathNSResolver" { | 20264 class XPathNSResolver native "*XPathNSResolver" { |
| 20258 | 20265 |
| 20259 /** @domName XPathNSResolver.lookupNamespaceURI */ | 20266 /** @domName XPathNSResolver.lookupNamespaceURI */ |
| 20260 String lookupNamespaceURI(String prefix) native; | 20267 String lookupNamespaceUri(String prefix) native "lookupNamespaceURI"; |
| 20261 } | 20268 } |
| 20262 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 20269 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 20263 // for details. All rights reserved. Use of this source code is governed by a | 20270 // for details. All rights reserved. Use of this source code is governed by a |
| 20264 // BSD-style license that can be found in the LICENSE file. | 20271 // BSD-style license that can be found in the LICENSE file. |
| 20265 | 20272 |
| 20266 | 20273 |
| 20267 /// @domName XPathResult | 20274 /// @domName XPathResult |
| 20268 class XPathResult native "*XPathResult" { | 20275 class XPathResult native "*XPathResult" { |
| 20269 | 20276 |
| 20270 static const int ANY_TYPE = 0; | 20277 static const int ANY_TYPE = 0; |
| (...skipping 3731 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 24002 } | 24009 } |
| 24003 } | 24010 } |
| 24004 | 24011 |
| 24005 class _DocumentFragmentFactoryProvider { | 24012 class _DocumentFragmentFactoryProvider { |
| 24006 /** @domName Document.createDocumentFragment */ | 24013 /** @domName Document.createDocumentFragment */ |
| 24007 static DocumentFragment createDocumentFragment() => | 24014 static DocumentFragment createDocumentFragment() => |
| 24008 document.createDocumentFragment(); | 24015 document.createDocumentFragment(); |
| 24009 | 24016 |
| 24010 static DocumentFragment createDocumentFragment_html(String html) { | 24017 static DocumentFragment createDocumentFragment_html(String html) { |
| 24011 final fragment = new DocumentFragment(); | 24018 final fragment = new DocumentFragment(); |
| 24012 fragment.innerHTML = html; | 24019 fragment.innerHtml = html; |
| 24013 return fragment; | 24020 return fragment; |
| 24014 } | 24021 } |
| 24015 | 24022 |
| 24016 // TODO(nweiz): enable this when XML is ported. | 24023 // TODO(nweiz): enable this when XML is ported. |
| 24017 // factory DocumentFragment.xml(String xml) { | 24024 // factory DocumentFragment.xml(String xml) { |
| 24018 // final fragment = new DocumentFragment(); | 24025 // final fragment = new DocumentFragment(); |
| 24019 // final e = new XMLElement.tag("xml"); | 24026 // final e = new XMLElement.tag("xml"); |
| 24020 // e.innerHTML = xml; | 24027 // e.innerHtml = xml; |
| 24021 // | 24028 // |
| 24022 // // Copy list first since we don't want liveness during iteration. | 24029 // // Copy list first since we don't want liveness during iteration. |
| 24023 // final List nodes = new List.from(e.nodes); | 24030 // final List nodes = new List.from(e.nodes); |
| 24024 // fragment.nodes.addAll(nodes); | 24031 // fragment.nodes.addAll(nodes); |
| 24025 // return fragment; | 24032 // return fragment; |
| 24026 // } | 24033 // } |
| 24027 | 24034 |
| 24028 static DocumentFragment createDocumentFragment_svg(String svgContent) { | 24035 static DocumentFragment createDocumentFragment_svg(String svgContent) { |
| 24029 final fragment = new DocumentFragment(); | 24036 final fragment = new DocumentFragment(); |
| 24030 final e = new svg.SVGSVGElement(); | 24037 final e = new svg.SVGSVGElement(); |
| 24031 e.innerHTML = svgContent; | 24038 e.innerHtml = svgContent; |
| 24032 | 24039 |
| 24033 // Copy list first since we don't want liveness during iteration. | 24040 // Copy list first since we don't want liveness during iteration. |
| 24034 final List nodes = new List.from(e.nodes); | 24041 final List nodes = new List.from(e.nodes); |
| 24035 fragment.nodes.addAll(nodes); | 24042 fragment.nodes.addAll(nodes); |
| 24036 return fragment; | 24043 return fragment; |
| 24037 } | 24044 } |
| 24038 } | 24045 } |
| 24039 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 24046 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 24040 // for details. All rights reserved. Use of this source code is governed by a | 24047 // for details. All rights reserved. Use of this source code is governed by a |
| 24041 // BSD-style license that can be found in the LICENSE file. | 24048 // BSD-style license that can be found in the LICENSE file. |
| (...skipping 968 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 25010 if (length < 0) throw new ArgumentError('length'); | 25017 if (length < 0) throw new ArgumentError('length'); |
| 25011 if (start < 0) throw new RangeError.value(start); | 25018 if (start < 0) throw new RangeError.value(start); |
| 25012 int end = start + length; | 25019 int end = start + length; |
| 25013 if (end > a.length) throw new RangeError.value(end); | 25020 if (end > a.length) throw new RangeError.value(end); |
| 25014 for (int i = start; i < end; i++) { | 25021 for (int i = start; i < end; i++) { |
| 25015 accumulator.add(a[i]); | 25022 accumulator.add(a[i]); |
| 25016 } | 25023 } |
| 25017 return accumulator; | 25024 return accumulator; |
| 25018 } | 25025 } |
| 25019 } | 25026 } |
| OLD | NEW |