Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(50)

Side by Side Diff: tools/dom/templates/html/impl/impl_SVGElement.darttemplate

Issue 1236793006: Fix type problem with FilteredElementList._iterable (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Review fixes Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests/html/html.status ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 part of $LIBRARYNAME; 5 part of $LIBRARYNAME;
6 6
7 class _AttributeClassSet extends CssClassSetImpl { 7 class _AttributeClassSet extends CssClassSetImpl {
8 final Element _element; 8 final Element _element;
9 9
10 _AttributeClassSet(this._element); 10 _AttributeClassSet(this._element);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 } else { 49 } else {
50 parentElement = new SvgSvgElement(); 50 parentElement = new SvgSvgElement();
51 } 51 }
52 var fragment = parentElement.createFragment(svg, validator: validator, 52 var fragment = parentElement.createFragment(svg, validator: validator,
53 treeSanitizer: treeSanitizer); 53 treeSanitizer: treeSanitizer);
54 return fragment.nodes.where((e) => e is SvgElement).single; 54 return fragment.nodes.where((e) => e is SvgElement).single;
55 } 55 }
56 56
57 CssClassSet get classes => new _AttributeClassSet(this); 57 CssClassSet get classes => new _AttributeClassSet(this);
58 58
59 List<Element> get children => new FilteredElementList<Element>(this); 59 List<Element> get children => new FilteredElementList(this);
60 60
61 void set children(List<Element> value) { 61 void set children(List<Element> value) {
62 final children = this.children; 62 final children = this.children;
63 children.clear(); 63 children.clear();
64 children.addAll(value); 64 children.addAll(value);
65 } 65 }
66 66
67 String get outerHtml { 67 String get outerHtml {
68 final container = new Element.tag("div"); 68 final container = new Element.tag("div");
69 final SvgElement cloned = this.clone(true); 69 final SvgElement cloned = this.clone(true);
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 * Checks to see if the SVG element type is supported by the current platform. 138 * Checks to see if the SVG element type is supported by the current platform.
139 * 139 *
140 * The tag should be a valid SVG element tag name. 140 * The tag should be a valid SVG element tag name.
141 */ 141 */
142 static bool isTagSupported(String tag) { 142 static bool isTagSupported(String tag) {
143 var e = new $CLASSNAME.tag(tag); 143 var e = new $CLASSNAME.tag(tag);
144 return e is $CLASSNAME && !(e is UnknownElement); 144 return e is $CLASSNAME && !(e is UnknownElement);
145 } 145 }
146 $!MEMBERS 146 $!MEMBERS
147 } 147 }
OLDNEW
« no previous file with comments | « tests/html/html.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698