| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 class FilteredElementList implements ElementList { | 5 class FilteredElementList implements ElementList { |
| 6 final Node _node; | 6 final Node _node; |
| 7 final NodeList _childNodes; | 7 final NodeList _childNodes; |
| 8 | 8 |
| 9 FilteredElementList(Node node): _childNodes = node.nodes, _node = node; | 9 FilteredElementList(Node node): _childNodes = node.nodes, _node = node; |
| 10 | 10 |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 int indexOf(Element element, int startIndex) => | 102 int indexOf(Element element, int startIndex) => |
| 103 _filtered.indexOf(element, startIndex); | 103 _filtered.indexOf(element, startIndex); |
| 104 int lastIndexOf(Element element, int startIndex) => | 104 int lastIndexOf(Element element, int startIndex) => |
| 105 _filtered.lastIndexOf(element, startIndex); | 105 _filtered.lastIndexOf(element, startIndex); |
| 106 Element last() => _filtered.last(); | 106 Element last() => _filtered.last(); |
| 107 } | 107 } |
| 108 | 108 |
| 109 class EmptyStyleDeclaration extends CSSStyleDeclarationWrappingImplementation { | 109 class EmptyStyleDeclaration extends CSSStyleDeclarationWrappingImplementation { |
| 110 // This can't call super(), since that's a factory constructor | 110 // This can't call super(), since that's a factory constructor |
| 111 EmptyStyleDeclaration() | 111 EmptyStyleDeclaration() |
| 112 : super._wrap(dom.document.createElement('div').style) {} | 112 : super._wrap(dom.document.createElement('div').style); |
| 113 | 113 |
| 114 void set cssText(String value) { | 114 void set cssText(String value) { |
| 115 throw new UnsupportedOperationException( | 115 throw new UnsupportedOperationException( |
| 116 "Can't modify a frozen style declaration."); | 116 "Can't modify a frozen style declaration."); |
| 117 } | 117 } |
| 118 | 118 |
| 119 String removeProperty(String propertyName) { | 119 String removeProperty(String propertyName) { |
| 120 throw new UnsupportedOperationException( | 120 throw new UnsupportedOperationException( |
| 121 "Can't modify a frozen style declaration."); | 121 "Can't modify a frozen style declaration."); |
| 122 } | 122 } |
| (...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 void set title(String value) { | 356 void set title(String value) { |
| 357 throw new UnsupportedOperationException( | 357 throw new UnsupportedOperationException( |
| 358 "Title can't be set for document fragments."); | 358 "Title can't be set for document fragments."); |
| 359 } | 359 } |
| 360 | 360 |
| 361 void set webkitdropzone(String value) { | 361 void set webkitdropzone(String value) { |
| 362 throw new UnsupportedOperationException( | 362 throw new UnsupportedOperationException( |
| 363 "WebKit drop zone can't be set for document fragments."); | 363 "WebKit drop zone can't be set for document fragments."); |
| 364 } | 364 } |
| 365 } | 365 } |
| OLD | NEW |