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

Unified Diff: lib/html/scripts/htmlrenamer.py

Issue 10941047: Don't generate FooList if it behaves like List<Foo> exactly. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: lib/html/scripts/htmlrenamer.py
===================================================================
--- lib/html/scripts/htmlrenamer.py (revision 12656)
+++ lib/html/scripts/htmlrenamer.py (working copy)
@@ -3,9 +3,22 @@
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
-_html_interface_renames = {
+html_interface_renames = {
+ 'ClientRectList': 'List<ClientRect>',
+ 'CSSRuleList': 'List<CSSRule>',
+ 'CSSValueList': 'List<CSSValue>',
'DOMFormData': 'FormData',
'DOMWindow': 'Window',
+ 'EntryArray': 'List<Entry>',
+ 'EntryArraySync': 'List<EntrySync>',
+ 'FileList': 'List<File>',
+ 'GamepadList': 'List<Gamepad>',
+ 'MediaStreamList': 'List<MediaStream>',
+ 'SVGElementInstanceList': 'List<SVGElementInstance>',
+ 'SVGPathSegList': 'List<SVGPathSeg>',
+ 'SpeechInputResultList': 'List<SpeechInputResult>',
+ 'SpeechRecognitionResultList': 'List<SpeechRecognitionResult>',
+ 'StyleSheetList': 'List<StyleSheet>',
'WebKitAnimation': 'Animation',
'WebKitAnimationEvent': 'AnimationEvent',
'WebKitAnimationList': 'AnimationList',
@@ -279,8 +292,8 @@
if any(interface.id in ['Element', 'Document']
for interface in self._database.Hierarchy(interface)):
return interface.id[len('HTML'):]
- elif interface.id in _html_interface_renames:
- return _html_interface_renames[interface.id]
+ elif interface.id in html_interface_renames:
+ return html_interface_renames[interface.id]
return interface.id
def RenameMember(self, interface_name, member, member_prefix=''):

Powered by Google App Engine
This is Rietveld 408576698