| 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 part of html; | 5 part of html; |
| 6 $ANNOTATIONS | 6 |
| 7 /** | 7 /** |
| 8 * The base class for all documents. | 8 * The base class for all documents. |
| 9 * | 9 * |
| 10 * Each web page loaded in the browser has its own [Document] object, which is | 10 * Each web page loaded in the browser has its own [Document] object, which is |
| 11 * typically an [HtmlDocument]. | 11 * typically an [HtmlDocument]. |
| 12 * | 12 * |
| 13 * If you aren't comfortable with DOM concepts, see the Dart tutorial | 13 * If you aren't comfortable with DOM concepts, see the Dart tutorial |
| 14 * [Target 2: Connect Dart & HTML](http://www.dartlang.org/docs/tutorials/connec
t-dart-html/). | 14 * [Target 2: Connect Dart & HTML](http://www.dartlang.org/docs/tutorials/connec
t-dart-html/). |
| 15 */ | 15 */ |
| 16 class $CLASSNAME extends Node $NATIVESPEC | 16 $(ANNOTATIONS)class $CLASSNAME extends Node $NATIVESPEC |
| 17 { | 17 { |
| 18 | 18 |
| 19 $!MEMBERS | 19 $!MEMBERS |
| 20 | 20 |
| 21 /** | 21 /** |
| 22 * Finds the first descendant element of this document that matches the | 22 * Finds the first descendant element of this document that matches the |
| 23 * specified group of selectors. | 23 * specified group of selectors. |
| 24 * | 24 * |
| 25 * Unless your webpage contains multiple documents, the top-level query | 25 * Unless your webpage contains multiple documents, the top-level query |
| 26 * method behaves the same as this method, so you should use it instead to | 26 * method behaves the same as this method, so you should use it instead to |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 final copyOfMatches = new List<Element>.fixedLength(len); | 72 final copyOfMatches = new List<Element>.fixedLength(len); |
| 73 for (int i = 0; i < len; ++i) { | 73 for (int i = 0; i < len; ++i) { |
| 74 copyOfMatches[i] = mutableMatches[i]; | 74 copyOfMatches[i] = mutableMatches[i]; |
| 75 } | 75 } |
| 76 return new _FrozenElementList._wrap(copyOfMatches); | 76 return new _FrozenElementList._wrap(copyOfMatches); |
| 77 } else { | 77 } else { |
| 78 return new _FrozenElementList._wrap($dom_querySelectorAll(selectors)); | 78 return new _FrozenElementList._wrap($dom_querySelectorAll(selectors)); |
| 79 } | 79 } |
| 80 } | 80 } |
| 81 } | 81 } |
| OLD | NEW |