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

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

Issue 12580012: Patchable version of 12929005 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 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/html/typed_arrays_range_checks_test.dart ('k') | tools/dom/scripts/generator.py » ('j') | 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) 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 """This is the entry point to create Dart APIs from the IDL database.""" 6 """This is the entry point to create Dart APIs from the IDL database."""
7 7
8 import dartgenerator 8 import dartgenerator
9 import database 9 import database
10 import fremontcutbuilder 10 import fremontcutbuilder
(...skipping 11 matching lines...) Expand all
22 from systemhtml import DartLibraryEmitter, Dart2JSBackend,\ 22 from systemhtml import DartLibraryEmitter, Dart2JSBackend,\
23 HtmlDartInterfaceGenerator, DartLibrary, DartLibraries 23 HtmlDartInterfaceGenerator, DartLibrary, DartLibraries
24 from systemnative import CPPLibraryEmitter, DartiumBackend 24 from systemnative import CPPLibraryEmitter, DartiumBackend
25 from templateloader import TemplateLoader 25 from templateloader import TemplateLoader
26 26
27 sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..')) 27 sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..'))
28 import utils 28 import utils
29 29
30 _logger = logging.getLogger('dartdomgenerator') 30 _logger = logging.getLogger('dartdomgenerator')
31 31
32 _libraries = ['chrome', 'html', 'indexed_db', 'svg', 'web_audio', 'web_sql'] 32 _libraries = ['chrome', 'html', 'indexed_db', 'svg', 'typeddata',
33 'web_audio', 'web_sql']
33 34
34 class GeneratorOptions(object): 35 class GeneratorOptions(object):
35 def __init__(self, templates, database, type_registry, renamer): 36 def __init__(self, templates, database, type_registry, renamer):
36 self.templates = templates 37 self.templates = templates
37 self.database = database 38 self.database = database
38 self.type_registry = type_registry 39 self.type_registry = type_registry
39 self.renamer = renamer 40 self.renamer = renamer
40 41
41 def LoadDatabase(database_dir, use_database_cache): 42 def LoadDatabase(database_dir, use_database_cache):
42 common_database = database.Database(database_dir) 43 common_database = database.Database(database_dir)
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 os.path.join('..', '..', '..', 'sdk', 'lib', library_name, 'dart2js')) 201 os.path.join('..', '..', '..', 'sdk', 'lib', library_name, 'dart2js'))
201 if 'htmldartium' in systems: 202 if 'htmldartium' in systems:
202 _logger.info('Generating dartium single files.') 203 _logger.info('Generating dartium single files.')
203 for library_name in _libraries: 204 for library_name in _libraries:
204 GenerateSingleFile( 205 GenerateSingleFile(
205 os.path.join(dartium_output_dir, '%s_dartium.dart' % library_name), 206 os.path.join(dartium_output_dir, '%s_dartium.dart' % library_name),
206 os.path.join('..', '..', '..', 'sdk', 'lib', library_name, 'dartium')) 207 os.path.join('..', '..', '..', 'sdk', 'lib', library_name, 'dartium'))
207 208
208 if __name__ == '__main__': 209 if __name__ == '__main__':
209 sys.exit(main()) 210 sys.exit(main())
OLDNEW
« no previous file with comments | « tests/html/typed_arrays_range_checks_test.dart ('k') | tools/dom/scripts/generator.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698