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

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

Issue 37203003: Dartium fixes for latest Blink rolls. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 2 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 | « tools/dom/scripts/htmlrenamer.py ('k') | tools/dom/templates/html/dartium/cpp_header.template » ('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) 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 for the systems to generate 6 """This module provides shared functionality for the systems to generate
7 native binding from the IDL database.""" 7 native binding from the IDL database."""
8 8
9 import emitter 9 import emitter
10 import os 10 import os
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 ('Navigator', 'webkitPersistentStorage'): 'NavigatorStorageQuota', 44 ('Navigator', 'webkitPersistentStorage'): 'NavigatorStorageQuota',
45 ('Navigator', 'webkitTemporaryStorage'): 'NavigatorStorageQuota', 45 ('Navigator', 'webkitTemporaryStorage'): 'NavigatorStorageQuota',
46 ('Navigator', 'registerProtocolHandler'): 'NavigatorContentUtils', 46 ('Navigator', 'registerProtocolHandler'): 'NavigatorContentUtils',
47 ('Navigator', 'unregisterProtocolHandler'): 'NavigatorContentUtils', 47 ('Navigator', 'unregisterProtocolHandler'): 'NavigatorContentUtils',
48 ('Navigator', 'webkitGetUserMedia'): 'NavigatorMediaStream', 48 ('Navigator', 'webkitGetUserMedia'): 'NavigatorMediaStream',
49 ('Navigator', 'webkitGetGamepads'): 'NavigatorGamepad', 49 ('Navigator', 'webkitGetGamepads'): 'NavigatorGamepad',
50 ('Navigator', 'requestMIDIAccess'): 'NavigatorWebMIDI', 50 ('Navigator', 'requestMIDIAccess'): 'NavigatorWebMIDI',
51 ('Navigator', 'vibrate'): 'NavigatorVibration', 51 ('Navigator', 'vibrate'): 'NavigatorVibration',
52 ('Navigator', 'appName'): 'NavigatorID', 52 ('Navigator', 'appName'): 'NavigatorID',
53 ('Navigator', 'appVersion'): 'NavigatorID', 53 ('Navigator', 'appVersion'): 'NavigatorID',
54 ('Navigator', 'appCodeName'): 'NavigatorID',
54 ('Navigator', 'platform'): 'NavigatorID', 55 ('Navigator', 'platform'): 'NavigatorID',
56 ('Navigator', 'product'): 'NavigatorID',
55 ('Navigator', 'userAgent'): 'NavigatorID', 57 ('Navigator', 'userAgent'): 'NavigatorID',
56 ('Navigator', 'onLine'): 'NavigatorOnLine', 58 ('Navigator', 'onLine'): 'NavigatorOnLine',
59 ('Navigator', 'registerServiceWorker'): 'NavigatorServiceWorker',
60 ('Navigator', 'unregisterServiceWorker'): 'NavigatorServiceWorker',
57 ('WorkerGlobalScope', 'crypto'): 'WorkerGlobalScopeCrypto', 61 ('WorkerGlobalScope', 'crypto'): 'WorkerGlobalScopeCrypto',
58 ('WorkerGlobalScope', 'indexedDB'): 'WorkerGlobalScopeIndexedDatabase', 62 ('WorkerGlobalScope', 'indexedDB'): 'WorkerGlobalScopeIndexedDatabase',
59 ('WorkerGlobalScope', 'webkitNotifications'): 'WorkerGlobalScopeNotifications' , 63 ('WorkerGlobalScope', 'webkitNotifications'): 'WorkerGlobalScopeNotifications' ,
60 ('WorkerGlobalScope', 'openDatabase'): 'WorkerGlobalScopeWebDatabase', 64 ('WorkerGlobalScope', 'openDatabase'): 'WorkerGlobalScopeWebDatabase',
61 ('WorkerGlobalScope', 'openDatabaseSync'): 'WorkerGlobalScopeWebDatabase', 65 ('WorkerGlobalScope', 'openDatabaseSync'): 'WorkerGlobalScopeWebDatabase',
62 ('WorkerGlobalScope', 'performance'): 'WorkerGlobalScopePerformance', 66 ('WorkerGlobalScope', 'performance'): 'WorkerGlobalScopePerformance',
63 ('WorkerGlobalScope', 'webkitRequestFileSystem'): 'WorkerGlobalScopeFileSystem ', 67 ('WorkerGlobalScope', 'webkitRequestFileSystem'): 'WorkerGlobalScopeFileSystem ',
64 ('WorkerGlobalScope', 'webkitRequestFileSystemSync'): 'WorkerGlobalScopeFileSy stem', 68 ('WorkerGlobalScope', 'webkitRequestFileSystemSync'): 'WorkerGlobalScopeFileSy stem',
65 ('WorkerGlobalScope', 'webkitResolveLocalFileSystemURL'): 'WorkerGlobalScopeFi leSystem', 69 ('WorkerGlobalScope', 'webkitResolveLocalFileSystemURL'): 'WorkerGlobalScopeFi leSystem',
66 ('WorkerGlobalScope', 'webkitResolveLocalFileSystemSyncURL'): 'WorkerGlobalSco peFileSystem', 70 ('WorkerGlobalScope', 'webkitResolveLocalFileSystemSyncURL'): 'WorkerGlobalSco peFileSystem',
(...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after
872 ' ScriptState& state = *currentState;\n\n') 876 ' ScriptState& state = *currentState;\n\n')
873 877
874 if requires_dom_window or requires_document: 878 if requires_dom_window or requires_document:
875 self._cpp_impl_includes.add('"DOMWindow.h"') 879 self._cpp_impl_includes.add('"DOMWindow.h"')
876 body_emitter.Emit( 880 body_emitter.Emit(
877 ' DOMWindow* domWindow = DartUtilities::domWindowForCurrentIsol ate();\n' 881 ' DOMWindow* domWindow = DartUtilities::domWindowForCurrentIsol ate();\n'
878 ' if (!domWindow) {\n' 882 ' if (!domWindow) {\n'
879 ' exception = Dart_NewStringFromCString("Failed to fetch do mWindow");\n' 883 ' exception = Dart_NewStringFromCString("Failed to fetch do mWindow");\n'
880 ' goto fail;\n' 884 ' goto fail;\n'
881 ' }\n' 885 ' }\n'
882 ' Document* document = domWindow->document();\n') 886 ' Document& document = *domWindow->document();\n')
883 887
884 if needs_receiver: 888 if needs_receiver:
885 body_emitter.Emit( 889 body_emitter.Emit(
886 ' $WEBCORE_CLASS_NAME* receiver = DartDOMWrapper::receiver< $WE BCORE_CLASS_NAME >(args);\n', 890 ' $WEBCORE_CLASS_NAME* receiver = DartDOMWrapper::receiver< $WE BCORE_CLASS_NAME >(args);\n',
887 WEBCORE_CLASS_NAME=self._interface_type_info.native_type()) 891 WEBCORE_CLASS_NAME=self._interface_type_info.native_type())
888 892
889 if requires_stack_info: 893 if requires_stack_info:
890 self._cpp_impl_includes.add('"ScriptArguments.h"') 894 self._cpp_impl_includes.add('"ScriptArguments.h"')
891 self._cpp_impl_includes.add('"ScriptCallStack.h"') 895 self._cpp_impl_includes.add('"ScriptCallStack.h"')
892 body_emitter.Emit( 896 body_emitter.Emit(
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
1276 e.Emit('\n'); 1280 e.Emit('\n');
1277 e.Emit('} // namespace WebCore\n'); 1281 e.Emit('} // namespace WebCore\n');
1278 self._emitters.Flush() 1282 self._emitters.Flush()
1279 1283
1280 def _IsOptionalStringArgumentInInitEventMethod(interface, operation, argument): 1284 def _IsOptionalStringArgumentInInitEventMethod(interface, operation, argument):
1281 return ( 1285 return (
1282 interface.id.endswith('Event') and 1286 interface.id.endswith('Event') and
1283 operation.id.startswith('init') and 1287 operation.id.startswith('init') and
1284 argument.ext_attrs.get('Default') == 'Undefined' and 1288 argument.ext_attrs.get('Default') == 'Undefined' and
1285 argument.type.id == 'DOMString') 1289 argument.type.id == 'DOMString')
OLDNEW
« no previous file with comments | « tools/dom/scripts/htmlrenamer.py ('k') | tools/dom/templates/html/dartium/cpp_header.template » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698