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

Side by Side Diff: tools/dom/scripts/dartmetadata.py

Issue 1093243002: getElementsByName returns HtmlCollection on IE (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: un-suppress passing tests Created 5 years, 8 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
« no previous file with comments | « tests/co19/co19-dart2js.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 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 """This module provides shared functionality to provide Dart metadata for 6 """This module provides shared functionality to provide Dart metadata for
7 DOM APIs. 7 DOM APIs.
8 """ 8 """
9 9
10 import copy 10 import copy
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 'CanvasRenderingContext2D.strokeStyle': [ 54 'CanvasRenderingContext2D.strokeStyle': [
55 "@Creates('String|CanvasGradient|CanvasPattern')", 55 "@Creates('String|CanvasGradient|CanvasPattern')",
56 "@Returns('String|CanvasGradient|CanvasPattern')", 56 "@Returns('String|CanvasGradient|CanvasPattern')",
57 ], 57 ],
58 58
59 'CustomEvent._detail': [ 59 'CustomEvent._detail': [
60 "@Creates('Null')", 60 "@Creates('Null')",
61 ], 61 ],
62 62
63 # Normally Window is nevernull, but starting from a <template> element in 63 # Normally Window is never null, but starting from a <template> element in
64 # JavaScript, this will be null: 64 # JavaScript, this will be null:
65 # template.content.ownerDocument.defaultView 65 # template.content.ownerDocument.defaultView
66 'Document.window': [ 66 'Document.window': [
67 "@Creates('Window|=Object|Null')", 67 "@Creates('Window|=Object|Null')",
68 "@Returns('Window|=Object|Null')", 68 "@Returns('Window|=Object|Null')",
69 ], 69 ],
70 70
71 'Document.getElementsByClassName': [
72 "@Creates('NodeList|HtmlCollection')",
73 "@Returns('NodeList|HtmlCollection')",
74 ],
75
76 'Document.getElementsByName': [
77 "@Creates('NodeList|HtmlCollection')",
78 "@Returns('NodeList|HtmlCollection')",
79 ],
80
71 'Document.getElementsByTagName': [ 81 'Document.getElementsByTagName': [
72 "@Creates('NodeList|HtmlCollection')", 82 "@Creates('NodeList|HtmlCollection')",
73 "@Returns('NodeList|HtmlCollection')", 83 "@Returns('NodeList|HtmlCollection')",
74 ], 84 ],
75
76 'Document.getElementsByClassName': [
77 "@Creates('NodeList|HtmlCollection')",
78 "@Returns('NodeList|HtmlCollection')",
79 ],
80 85
81 # Methods returning Window can return a local window, or a cross-frame 86 # Methods returning Window can return a local window, or a cross-frame
82 # window (=Object) that needs wrapping. 87 # window (=Object) that needs wrapping.
83 'Window': [ 88 'Window': [
84 "@Creates('Window|=Object')", 89 "@Creates('Window|=Object')",
85 "@Returns('Window|=Object')", 90 "@Returns('Window|=Object')",
86 ], 91 ],
87 92
88 'Window.openDatabase': [ 93 'Window.openDatabase': [
89 "@Creates('SqlDatabase')", 94 "@Creates('SqlDatabase')",
90 ], 95 ],
91 96
92 'Window.showModalDialog': [ 97 'Window.showModalDialog': [
93 "@Creates('Null')", 98 "@Creates('Null')",
94 ], 99 ],
95 100
96 'Element.webkitGetRegionFlowRanges': [ 101 'Element.webkitGetRegionFlowRanges': [
97 "@Creates('JSExtendableArray')", 102 "@Creates('JSExtendableArray')",
98 "@Returns('JSExtendableArray')", 103 "@Returns('JSExtendableArray')",
99 ], 104 ],
100 105
106 'Element.getElementsByClassName': [
107 "@Creates('NodeList|HtmlCollection')",
108 "@Returns('NodeList|HtmlCollection')",
109 ],
110
111 'Element.getElementsByName': [
112 "@Creates('NodeList|HtmlCollection')",
113 "@Returns('NodeList|HtmlCollection')",
114 ],
115
101 'Element.getElementsByTagName': [ 116 'Element.getElementsByTagName': [
102 "@Creates('NodeList|HtmlCollection')", 117 "@Creates('NodeList|HtmlCollection')",
103 "@Returns('NodeList|HtmlCollection')", 118 "@Returns('NodeList|HtmlCollection')",
104 ], 119 ],
105
106 'Element.getElementsByClassName': [
107 "@Creates('NodeList|HtmlCollection')",
108 "@Returns('NodeList|HtmlCollection')",
109 ],
110 120
111 "ErrorEvent.error": [ 121 "ErrorEvent.error": [
112 "@Creates('Null')", # Only returns values created elsewhere. 122 "@Creates('Null')", # Only returns values created elsewhere.
113 ], 123 ],
114 124
115 # To be in callback with the browser-created Event, we had to have called 125 # To be in callback with the browser-created Event, we had to have called
116 # addEventListener on the target, so we avoid 126 # addEventListener on the target, so we avoid
117 'Event.currentTarget': [ 127 'Event.currentTarget': [
118 "@Creates('Null')", 128 "@Creates('Null')",
119 "@Returns('EventTarget|=Object')", 129 "@Returns('EventTarget|=Object')",
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 283
274 'RTCStatsReport.timestamp': [ 284 'RTCStatsReport.timestamp': [
275 "@Creates('Null')", # JS date object. 285 "@Creates('Null')", # JS date object.
276 ], 286 ],
277 287
278 'SerializedScriptValue': [ 288 'SerializedScriptValue': [
279 "@annotation_Creates_SerializedScriptValue", 289 "@annotation_Creates_SerializedScriptValue",
280 "@annotation_Returns_SerializedScriptValue", 290 "@annotation_Returns_SerializedScriptValue",
281 ], 291 ],
282 292
293 'ShadowRoot.getElementsByClassName': [
294 "@Creates('NodeList|HtmlCollection')",
295 "@Returns('NodeList|HtmlCollection')",
296 ],
297
298 'ShadowRoot.getElementsByName': [
299 "@Creates('NodeList|HtmlCollection')",
300 "@Returns('NodeList|HtmlCollection')",
301 ],
302
283 'ShadowRoot.getElementsByTagName': [ 303 'ShadowRoot.getElementsByTagName': [
284 "@Creates('NodeList|HtmlCollection')", 304 "@Creates('NodeList|HtmlCollection')",
285 "@Returns('NodeList|HtmlCollection')", 305 "@Returns('NodeList|HtmlCollection')",
286 ], 306 ],
287
288 'ShadowRoot.getElementsByClassName': [
289 "@Creates('NodeList|HtmlCollection')",
290 "@Returns('NodeList|HtmlCollection')",
291 ],
292 307
293 'SQLResultSetRowList.item': ["@Creates('=Object')"], 308 'SQLResultSetRowList.item': ["@Creates('=Object')"],
294 309
295 # Touch targets are Elements in a Document, or the Document. 310 # Touch targets are Elements in a Document, or the Document.
296 'Touch.target': [ 311 'Touch.target': [
297 "@Creates('Element|Document')", 312 "@Creates('Element|Document')",
298 "@Returns('Element|Document')", 313 "@Returns('Element|Document')",
299 ], 314 ],
300 315
301 'TrackEvent.track': [ 316 'TrackEvent.track': [
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
840 pass 855 pass
841 else: 856 else:
842 _logger.warn('Unknown support_level - %s:%s' % (interface_id, member_id)) 857 _logger.warn('Unknown support_level - %s:%s' % (interface_id, member_id))
843 858
844 return annotations 859 return annotations
845 860
846 def Flush(self): 861 def Flush(self):
847 json_file = open(self._api_status_path, 'w+') 862 json_file = open(self._api_status_path, 'w+')
848 json.dump(self._types, json_file, indent=2, separators=(',', ': '), sort_key s=True) 863 json.dump(self._types, json_file, indent=2, separators=(',', ': '), sort_key s=True)
849 json_file.close() 864 json_file.close()
OLDNEW
« no previous file with comments | « tests/co19/co19-dart2js.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698