| Index: Source/WebCore/bindings/dart/gyp/scripts/build_dart_snapshot.py
|
| diff --git a/Source/WebCore/bindings/dart/gyp/scripts/build_dart_snapshot.py b/Source/WebCore/bindings/dart/gyp/scripts/build_dart_snapshot.py
|
| index a9bff518db6eef7596f39e908b131601e7216ba8..955ee4feb7476a72a10ff7ccbf3fe504bf76c3df 100644
|
| --- a/Source/WebCore/bindings/dart/gyp/scripts/build_dart_snapshot.py
|
| +++ b/Source/WebCore/bindings/dart/gyp/scripts/build_dart_snapshot.py
|
| @@ -79,36 +79,12 @@ def main(args):
|
|
|
| dartScriptDir = os.path.join(dartPath, 'client', 'dom', 'scripts')
|
| sys.path.insert(0, dartScriptDir)
|
| -
|
| import fremontcutbuilder
|
| - fremontcutbuilder.main()
|
| -
|
| import dartdomgenerator
|
| - dartdomgenerator.GenerateDOM(systems=['native'], output_dir=outputFilePath)
|
|
|
| - # FIXME: proper support of enabled features.
|
| - EXCLUDED = [
|
| - 'WebKitMutationObserver',
|
| - 'WebKitCSSFilterValue',
|
| - 'MutationRecord',
|
| - 'HTMLDataListElement',
|
| - 'HTMLPropertiesCollection',
|
| - 'DOMWindowWebAudio',
|
| - 'DOMWindowWebSocket',
|
| - 'Intent',
|
| - 'NavigatorGamepad',
|
| - ]
|
| -
|
| - interfaceNames = []
|
| - idlListFile = open(idlListFileName, 'r')
|
| - for idlFileName in idlListFile:
|
| - if not idlFileName:
|
| - continue
|
| - interfaceName = os.path.splitext(os.path.basename(idlFileName))[0]
|
| - if interfaceName in EXCLUDED:
|
| - continue
|
| - interfaceNames.append(interfaceName)
|
| - idlListFile.close()
|
| + fremontcutbuilder.main()
|
| + # FIXME: pass the list of idl files and enabled features to generator.
|
| + dartdomgenerator.GenerateDOM(systems=['native'], output_dir=outputFilePath)
|
|
|
| def write(name, template, **kwargs):
|
| f = open(os.path.join(outputFilePath, name), 'w')
|
| @@ -124,35 +100,6 @@ def main(args):
|
| #import("dart:json", prefix: "json");
|
| ''', copyrightTemplate=copyrightTemplate)
|
|
|
| -
|
| - # Generate resolver.
|
| - resolverClasses = ['Dart' + interfaceName for interfaceName in interfaceNames if not interfaceName.endswith('Callback')]
|
| -
|
| - def forAllClasses(s):
|
| - return ''.join([s % className for className in resolverClasses])
|
| -
|
| - write('DartResolver.cpp', '''
|
| -%(copyrightTemplate)s
|
| -
|
| -#include "config.h"
|
| -%(includes)s
|
| -
|
| -namespace WebCore {
|
| -
|
| -Dart_NativeFunction snapshotResolver(Dart_Handle name, int argumentCount)
|
| -{
|
| -%(classChecks)s
|
| - return 0;
|
| -}
|
| -
|
| -}
|
| -''', copyrightTemplate=copyrightTemplate,
|
| - includes=forAllClasses('#include "%s.h"\n'),
|
| - classChecks=forAllClasses('''
|
| - if (Dart_NativeFunction func = %s::resolver(name, argumentCount))
|
| - return func;
|
| -'''))
|
| -
|
| # Construct command line to execute the snapshot generator binary and invoke.
|
| def path(*components):
|
| return os.path.abspath(os.path.join(*components))
|
|
|