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

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

Issue 261913003: Set up some of the webgl native functions as leaf calls (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 7 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 | « no previous file | 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 # 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 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 ('Element', 'setAttribute', 'Callback'), 150 ('Element', 'setAttribute', 'Callback'),
151 ('Element', 'setAttributeNS', 'Callback'), 151 ('Element', 'setAttributeNS', 'Callback'),
152 ('Node', 'firstChild', 'Getter'), 152 ('Node', 'firstChild', 'Getter'),
153 ('Node', 'lastChild', 'Getter'), 153 ('Node', 'lastChild', 'Getter'),
154 ('Node', 'nextSibling', 'Getter'), 154 ('Node', 'nextSibling', 'Getter'),
155 ('Node', 'previousSibling', 'Getter'), 155 ('Node', 'previousSibling', 'Getter'),
156 ('Node', 'childNodes', 'Getter'), 156 ('Node', 'childNodes', 'Getter'),
157 ('Node', 'nodeType', 'Getter'), 157 ('Node', 'nodeType', 'Getter'),
158 ('NodeList', 'length', 'Getter'), 158 ('NodeList', 'length', 'Getter'),
159 ('NodeList', 'item', 'Callback'), 159 ('NodeList', 'item', 'Callback'),
160 ('WebGLRenderingContext', 'drawingBufferHeight', 'Getter'),
161 ('WebGLRenderingContext', 'drawingBufferWidth', 'Getter'),
162 ('WebGLRenderingContext', 'activeTexture', 'Callback'),
163 ('WebGLRenderingContext', 'attachShader', 'Callback'),
164 ('WebGLRenderingContext', 'bindAttribLocation', 'Callback'),
165 ('WebGLRenderingContext', 'bindBuffer', 'Callback'),
166 ('WebGLRenderingContext', 'bindFramebuffer', 'Callback'),
167 ('WebGLRenderingContext', 'bindRenderbuffer', 'Callback'),
168 ('WebGLRenderingContext', 'bindTexture', 'Callback'),
169 ('WebGLRenderingContext', 'blendColor', 'Callback'),
170 ('WebGLRenderingContext', 'blendEquation', 'Callback'),
171 ('WebGLRenderingContext', 'blendEquationSeparate', 'Callback'),
172 ('WebGLRenderingContext', 'blendFunc', 'Callback'),
173 ('WebGLRenderingContext', 'blendFuncSeparate', 'Callback'),
174 ('WebGLRenderingContext', 'checkFramebufferStatus', 'Callback'),
175 ('WebGLRenderingContext', 'clear', 'Callback'),
176 ('WebGLRenderingContext', 'clearColor', 'Callback'),
177 ('WebGLRenderingContext', 'clearDepth', 'Callback'),
178 ('WebGLRenderingContext', 'clearStencil', 'Callback'),
179 ('WebGLRenderingContext', 'colorMask', 'Callback'),
180 ('WebGLRenderingContext', 'compileShader', 'Callback'),
181 ('WebGLRenderingContext', 'compressedTexImage2D', 'Callback'),
182 ('WebGLRenderingContext', 'compressedTexSubImage2D', 'Callback'),
183 ('WebGLRenderingContext', 'copyTexImage2D', 'Callback'),
184 ('WebGLRenderingContext', 'copyTexSubImage2D', 'Callback'),
185 ('WebGLRenderingContext', 'cullFace', 'Callback'),
186 ('WebGLRenderingContext', 'deleteBuffer', 'Callback'),
187 ('WebGLRenderingContext', 'deleteFramebuffer', 'Callback'),
188 ('WebGLRenderingContext', 'deleteProgram', 'Callback'),
189 ('WebGLRenderingContext', 'deleteRenderbuffer', 'Callback'),
190 ('WebGLRenderingContext', 'deleteShader', 'Callback'),
191 ('WebGLRenderingContext', 'deleteTexture', 'Callback'),
192 ('WebGLRenderingContext', 'depthFunc', 'Callback'),
193 ('WebGLRenderingContext', 'depthMask', 'Callback'),
194 ('WebGLRenderingContext', 'depthRange', 'Callback'),
195 ('WebGLRenderingContext', 'detachShader', 'Callback'),
196 ('WebGLRenderingContext', 'disable', 'Callback'),
197 ('WebGLRenderingContext', 'disableVertexAttribArray', 'Callback'),
198 ('WebGLRenderingContext', 'drawArrays', 'Callback'),
199 ('WebGLRenderingContext', 'drawElements', 'Callback'),
200 ('WebGLRenderingContext', 'enable', 'Callback'),
201 ('WebGLRenderingContext', 'enableVertexAttribArray', 'Callback'),
202 ('WebGLRenderingContext', 'finish', 'Callback'),
203 ('WebGLRenderingContext', 'flush', 'Callback'),
204 ('WebGLRenderingContext', 'framebufferRenderbuffer', 'Callback'),
205 ('WebGLRenderingContext', 'framebufferTexture2D', 'Callback'),
206 ('WebGLRenderingContext', 'frontFace', 'Callback'),
207 ('WebGLRenderingContext', 'generateMipmap', 'Callback'),
208 ('WebGLRenderingContext', 'getActiveAttrib', 'Callback'),
209 ('WebGLRenderingContext', 'getActiveUniform', 'Callback'),
210 ('WebGLRenderingContext', 'getAttachedShaders', 'Callback'),
211 ('WebGLRenderingContext', 'getAttribLocation', 'Callback'),
212 ('WebGLRenderingContext', 'hint', 'Callback'),
213 ('WebGLRenderingContext', 'isBuffer', 'Callback'),
214 ('WebGLRenderingContext', 'isContextLost', 'Callback'),
215 ('WebGLRenderingContext', 'isEnabled', 'Callback'),
216 ('WebGLRenderingContext', 'isFramebuffer', 'Callback'),
217 ('WebGLRenderingContext', 'isProgram', 'Callback'),
218 ('WebGLRenderingContext', 'isRenderbuffer', 'Callback'),
219 ('WebGLRenderingContext', 'isShader', 'Callback'),
220 ('WebGLRenderingContext', 'isTexture', 'Callback'),
221 ('WebGLRenderingContext', 'lineWidth', 'Callback'),
222 ('WebGLRenderingContext', 'linkProgram', 'Callback'),
223 ('WebGLRenderingContext', 'pixelStorei', 'Callback'),
224 ('WebGLRenderingContext', 'polygonOffset', 'Callback'),
225 ('WebGLRenderingContext', 'scissor', 'Callback'),
226 ('WebGLRenderingContext', 'stencilFunc', 'Callback'),
227 ('WebGLRenderingContext', 'stencilFuncSeparate', 'Callback'),
228 ('WebGLRenderingContext', 'stencilMask', 'Callback'),
229 ('WebGLRenderingContext', 'stencilMaskSeparate', 'Callback'),
230 ('WebGLRenderingContext', 'stencilOp', 'Callback'),
231 ('WebGLRenderingContext', 'stencilOpSeparate', 'Callback'),
232 ('WebGLRenderingContext', 'uniform1f', 'Callback'),
233 ('WebGLRenderingContext', 'uniform1fv', 'Callback'),
234 ('WebGLRenderingContext', 'uniform1i', 'Callback'),
235 ('WebGLRenderingContext', 'uniform1iv', 'Callback'),
236 ('WebGLRenderingContext', 'uniform2f', 'Callback'),
237 ('WebGLRenderingContext', 'uniform2fv', 'Callback'),
238 ('WebGLRenderingContext', 'uniform2i', 'Callback'),
239 ('WebGLRenderingContext', 'uniform2iv', 'Callback'),
240 ('WebGLRenderingContext', 'uniform3f', 'Callback'),
241 ('WebGLRenderingContext', 'uniform3fv', 'Callback'),
242 ('WebGLRenderingContext', 'uniform3i', 'Callback'),
243 ('WebGLRenderingContext', 'uniform3iv', 'Callback'),
244 ('WebGLRenderingContext', 'uniform4f', 'Callback'),
245 ('WebGLRenderingContext', 'uniform4fv', 'Callback'),
246 ('WebGLRenderingContext', 'uniform4i', 'Callback'),
247 ('WebGLRenderingContext', 'uniform4iv', 'Callback'),
248 ('WebGLRenderingContext', 'uniformMatrix2fv', 'Callback'),
249 ('WebGLRenderingContext', 'uniformMatrix3fv', 'Callback'),
250 ('WebGLRenderingContext', 'uniformMatrix4fv', 'Callback'),
251 ('WebGLRenderingContext', 'useProgram', 'Callback'),
252 ('WebGLRenderingContext', 'validateProgram', 'Callback'),
253 ('WebGLRenderingContext', 'vertexAttrib1f', 'Callback'),
254 ('WebGLRenderingContext', 'vertexAttrib1fv', 'Callback'),
255 ('WebGLRenderingContext', 'vertexAttrib2f', 'Callback'),
256 ('WebGLRenderingContext', 'vertexAttrib2fv', 'Callback'),
257 ('WebGLRenderingContext', 'vertexAttrib3f', 'Callback'),
258 ('WebGLRenderingContext', 'vertexAttrib3fv', 'Callback'),
259 ('WebGLRenderingContext', 'vertexAttrib4f', 'Callback'),
260 ('WebGLRenderingContext', 'vertexAttrib4fv', 'Callback'),
261 ('WebGLRenderingContext', 'vertexAttribPointer', 'Callback'),
262 ('WebGLRenderingContext', 'viewport', 'Callback'),
160 ]) 263 ])
161 264
162 # TODO(vsm): This should be recoverable from IDL, but we appear to not 265 # TODO(vsm): This should be recoverable from IDL, but we appear to not
163 # track the necessary info. 266 # track the necessary info.
164 _url_utils = ['hash', 'host', 'hostname', 'origin', 267 _url_utils = ['hash', 'host', 'hostname', 'origin',
165 'password', 'pathname', 'port', 'protocol', 268 'password', 'pathname', 'port', 'protocol',
166 'search', 'username'] 269 'search', 'username']
167 _cpp_static_call_map = { 270 _cpp_static_call_map = {
168 'DOMURL': _url_utils + ['href', 'toString'], 271 'DOMURL': _url_utils + ['href', 'toString'],
169 'HTMLAnchorElement': _url_utils, 272 'HTMLAnchorElement': _url_utils,
(...skipping 1611 matching lines...) Expand 10 before | Expand all | Expand 10 after
1781 e.Emit("};\n"); 1884 e.Emit("};\n");
1782 e.Emit('\n'); 1885 e.Emit('\n');
1783 e.Emit('} // namespace WebCore\n'); 1886 e.Emit('} // namespace WebCore\n');
1784 1887
1785 def _IsOptionalStringArgumentInInitEventMethod(interface, operation, argument): 1888 def _IsOptionalStringArgumentInInitEventMethod(interface, operation, argument):
1786 return ( 1889 return (
1787 interface.id.endswith('Event') and 1890 interface.id.endswith('Event') and
1788 operation.id.startswith('init') and 1891 operation.id.startswith('init') and
1789 argument.ext_attrs.get('Default') == 'Undefined' and 1892 argument.ext_attrs.get('Default') == 'Undefined' and
1790 argument.type.id == 'DOMString') 1893 argument.type.id == 'DOMString')
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698