Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 2 # Copyright (c) 2011, 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 import database | 6 import database |
| 7 import databasebuilder | 7 import databasebuilder |
| 8 import idlparser | 8 import idlparser |
| 9 import logging.config | 9 import logging.config |
| 10 import os.path | 10 import os.path |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 94 'ENABLE_XHR_RESPONSE_BLOB', | 94 'ENABLE_XHR_RESPONSE_BLOB', |
| 95 'ENABLE_XSLT', | 95 'ENABLE_XSLT', |
| 96 ] | 96 ] |
| 97 webkit_options = databasebuilder.DatabaseBuilderOptions( | 97 webkit_options = databasebuilder.DatabaseBuilderOptions( |
| 98 idl_syntax=idlparser.WEBKIT_SYNTAX, | 98 idl_syntax=idlparser.WEBKIT_SYNTAX, |
| 99 # TODO(vsm): What else should we define as on when processing IDL? | 99 # TODO(vsm): What else should we define as on when processing IDL? |
| 100 idl_defines=webkit_defines, | 100 idl_defines=webkit_defines, |
| 101 source='WebKit', | 101 source='WebKit', |
| 102 source_attributes={'revision': webkit_revision}, | 102 source_attributes={'revision': webkit_revision}, |
| 103 type_rename_map={ | 103 type_rename_map={ |
| 104 # Some of these are typos in the IDL. | |
|
vsm
2012/04/09 19:23:30
Pavel: are these types gone from IDL or this remap
podivilov
2012/04/10 09:41:41
float and DOMObject are handled in idl registry in
| |
| 105 'float': 'double', | |
| 106 'BarInfo': 'BarProp', | 104 'BarInfo': 'BarProp', |
| 107 'DedicatedWorkerContext': 'DedicatedWorkerGlobalScope', | 105 'DedicatedWorkerContext': 'DedicatedWorkerGlobalScope', |
| 108 'DOMApplicationCache': 'ApplicationCache', | 106 'DOMApplicationCache': 'ApplicationCache', |
| 109 'DOMCoreException': 'DOMException', | 107 'DOMCoreException': 'DOMException', |
| 110 'DOMExceptionJSC': 'DOMException', # Node.replaceChild | |
| 111 'DomException': 'DOMException', # Navigator.registerProtocolHandler | |
| 112 'DOMFormData': 'FormData', | 108 'DOMFormData': 'FormData', |
| 113 'DOMObject': 'object', | |
| 114 'DOMSelection': 'Selection', | 109 'DOMSelection': 'Selection', |
| 115 'DOMWindow': 'Window', | 110 'DOMWindow': 'Window', |
| 116 'Exception': 'DOMException', # NotificationCenter.createNotification | |
| 117 'SharedWorkerContext': 'SharedWorkerGlobalScope', | 111 'SharedWorkerContext': 'SharedWorkerGlobalScope', |
| 118 'WorkerContext': 'WorkerGlobalScope', | 112 'WorkerContext': 'WorkerGlobalScope', |
| 119 }) | 113 }) |
| 120 | 114 |
| 121 optional_argument_whitelist = [ | 115 optional_argument_whitelist = [ |
| 122 ('CSSStyleDeclaration', 'setProperty', 'priority'), | 116 ('CSSStyleDeclaration', 'setProperty', 'priority'), |
| 123 ('IDBDatabase', 'transaction', 'mode'), | 117 ('IDBDatabase', 'transaction', 'mode'), |
| 124 ] | 118 ] |
| 125 | 119 |
| 126 # Import WebKit IDLs. | 120 # Import WebKit IDLs. |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 209 for dir_name in webkit_dirs: | 203 for dir_name in webkit_dirs: |
| 210 dir_path = os.path.join(webcore_dir, dir_name) | 204 dir_path = os.path.join(webcore_dir, dir_name) |
| 211 os.path.walk(dir_path, visitor, None) | 205 os.path.walk(dir_path, visitor, None) |
| 212 | 206 |
| 213 os.close(idl_list_file) | 207 os.close(idl_list_file) |
| 214 | 208 |
| 215 return build_database(idl_list_file_name) | 209 return build_database(idl_list_file_name) |
| 216 | 210 |
| 217 if __name__ == '__main__': | 211 if __name__ == '__main__': |
| 218 sys.exit(main()) | 212 sys.exit(main()) |
| OLD | NEW |