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

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

Issue 268313002: [dart:html] rename register to registerElement per spec (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: rebase Created 6 years, 7 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 | Annotate | Revision Log
OLDNEW
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 $LIBRARYNAME; 5 part of $LIBRARYNAME;
6 6
7 @DocsEditable() 7 @DocsEditable()
8 $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME extends Node $NATIVESPEC 8 $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME extends Node $NATIVESPEC
9 { 9 {
10 10
(...skipping 30 matching lines...) Expand all
41 /** 41 /**
42 * Alias for [querySelectorAll]. Note this function is deprecated because its 42 * Alias for [querySelectorAll]. Note this function is deprecated because its
43 * semantics will be changing in the future. 43 * semantics will be changing in the future.
44 */ 44 */
45 @deprecated 45 @deprecated
46 @Experimental() 46 @Experimental()
47 @DomName('Document.querySelectorAll') 47 @DomName('Document.querySelectorAll')
48 ElementList queryAll(String relativeSelectors) => 48 ElementList queryAll(String relativeSelectors) =>
49 querySelectorAll(relativeSelectors); 49 querySelectorAll(relativeSelectors);
50 50
51 /// Checks if [register] is supported on the current platform. 51 /// Checks if [registerElement] is supported on the current platform.
52 bool get supportsRegister { 52 bool get supportsRegisterElement {
53 $if DART2JS 53 $if DART2JS
54 return JS('bool', '("registerElement" in #)', this); 54 return JS('bool', '("registerElement" in #)', this);
55 $else 55 $else
56 return true; 56 return true;
57 $endif 57 $endif
58 } 58 }
59 59
60 /// *Deprecated*: use [supportsRegisterElement] instead.
61 @deprecated
62 bool get supportsRegister => supportsRegisterElement;
63
60 @DomName('Document.createElement') 64 @DomName('Document.createElement')
61 Element createElement(String tagName, [String typeExtension]) { 65 Element createElement(String tagName, [String typeExtension]) {
62 $if DART2JS 66 $if DART2JS
63 return _createElement(tagName, typeExtension); 67 return _createElement(tagName, typeExtension);
64 $else 68 $else
65 if (typeExtension != null) { 69 if (typeExtension != null) {
66 return _createElement(tagName, typeExtension); 70 return _createElement(tagName, typeExtension);
67 } else { 71 } else {
68 // Fast-path for Dartium when typeExtension is not needed. 72 // Fast-path for Dartium when typeExtension is not needed.
69 return _Utils.createElement(this, tagName); 73 return _Utils.createElement(this, tagName);
70 } 74 }
71 $endif 75 $endif
72 } 76 }
73 77
74 $if DART2JS 78 $if DART2JS
75 @DomName('Document.createNodeIterator') 79 @DomName('Document.createNodeIterator')
76 NodeIterator _createNodeIterator(Node root, 80 NodeIterator _createNodeIterator(Node root,
77 [int whatToShow, NodeFilter filter]) 81 [int whatToShow, NodeFilter filter])
78 => JS('NodeIterator', '#.createNodeIterator(#, #, #, false)', 82 => JS('NodeIterator', '#.createNodeIterator(#, #, #, false)',
79 this, root, whatToShow, filter); 83 this, root, whatToShow, filter);
80 84
81 @DomName('Document.createTreeWalker') 85 @DomName('Document.createTreeWalker')
82 TreeWalker _createTreeWalker(Node root, 86 TreeWalker _createTreeWalker(Node root,
83 [int whatToShow, NodeFilter filter]) 87 [int whatToShow, NodeFilter filter])
84 => JS('TreeWalker', '#.createTreeWalker(#, #, #, false)', 88 => JS('TreeWalker', '#.createTreeWalker(#, #, #, false)',
85 this, root, whatToShow, filter); 89 this, root, whatToShow, filter);
86 $endif 90 $endif
87 } 91 }
OLDNEW
« no previous file with comments | « tests/html/custom_elements_test.dart ('k') | tools/dom/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698