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

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

Issue 1847543003: Fast path Location.hash as some apps call it 10000+ times a frame. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: TBR Created 4 years, 8 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
« no previous file with comments | « tools/deps/dartium.deps/DEPS ('k') | no next file » | 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 # 2 #
3 # Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 3 # Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
4 # for details. All rights reserved. Use of this source code is governed by a 4 # for details. All rights reserved. Use of this source code is governed by a
5 # BSD-style license that can be found in the LICENSE file. 5 # BSD-style license that can be found in the LICENSE file.
6 6
7 """Generates sdk/lib/_blink/dartium/_blink_dartium.dart file.""" 7 """Generates sdk/lib/_blink/dartium/_blink_dartium.dart file."""
8 8
9 import os 9 import os
10 from sets import Set 10 from sets import Set
(...skipping 22 matching lines...) Expand all
33 'Node.parentNode', 33 'Node.parentNode',
34 'Node.childNodes', 34 'Node.childNodes',
35 'Node.removeChild', 35 'Node.removeChild',
36 'Node.contains', 36 'Node.contains',
37 'Node.nextSibling', 37 'Node.nextSibling',
38 'Node.previousSibling', 38 'Node.previousSibling',
39 'ChildNode.remove', 39 'ChildNode.remove',
40 'Document.createTextNode', 40 'Document.createTextNode',
41 'Window.location', 41 'Window.location',
42 'Location.href', 42 'Location.href',
43 'Location.hash',
43 'Node.querySelector', 44 'Node.querySelector',
44 45
45 'HTMLElement.hidden', 46 'HTMLElement.hidden',
46 'HTMLElement.style', 47 'HTMLElement.style',
47 'Element.attributes', 48 'Element.attributes',
48 'Window.innerWidth', 49 'Window.innerWidth',
49 50
50 'NodeList.length', 51 'NodeList.length',
51 'NodeList.item', 52 'NodeList.item',
52 'ParentNode.children', 53 'ParentNode.children',
(...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after
555 else: 556 else:
556 arguments = [] 557 arguments = []
557 for i in range(0, callback_index): 558 for i in range(0, callback_index):
558 arguments.append(ARGUMENT_NUM % i) 559 arguments.append(ARGUMENT_NUM % i)
559 argument_list = ', '.join(arguments) 560 argument_list = ', '.join(arguments)
560 if operation.is_static: 561 if operation.is_static:
561 class_property = CLASS_STATIC % interface.id 562 class_property = CLASS_STATIC % interface.id
562 blink_file.write(Select_Stub(STATIC_OPERATION_ARGS, is_native) % (name, callback_index, argument_list, class_property, interface.id, name, argument_list )) 563 blink_file.write(Select_Stub(STATIC_OPERATION_ARGS, is_native) % (name, callback_index, argument_list, class_property, interface.id, name, argument_list ))
563 else: 564 else:
564 blink_file.write(Select_Stub(OPERATION_ARGS, is_native) % (name, callbac k_index, argument_list, interface.id, name, argument_list)) 565 blink_file.write(Select_Stub(OPERATION_ARGS, is_native) % (name, callbac k_index, argument_list, interface.id, name, argument_list))
OLDNEW
« no previous file with comments | « tools/deps/dartium.deps/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698