Chromium Code Reviews| Index: sdk/lib/html/scripts/systemnative.py |
| diff --git a/sdk/lib/html/scripts/systemnative.py b/sdk/lib/html/scripts/systemnative.py |
| index 7155f29183a78748b268d39ed9811e4e4bbd0a75..336786d4ad6d3e0943d4b1d0060477db2d6da9ce 100644 |
| --- a/sdk/lib/html/scripts/systemnative.py |
| +++ b/sdk/lib/html/scripts/systemnative.py |
| @@ -9,7 +9,6 @@ native binding from the IDL database.""" |
| import emitter |
| import os |
| from generator import * |
| -from systemhtml import SecureOutputType |
| from htmldartgenerator import * |
| class DartiumBackend(HtmlDartGenerator): |
| @@ -287,14 +286,14 @@ class DartiumBackend(HtmlDartGenerator): |
| TO_NATIVE=to_native_emitter.Fragments(), |
| TO_DART=to_dart_emitter.Fragments()) |
| - def AddAttribute(self, attribute, html_name, read_only): |
| + def EmitAttribute(self, attribute, html_name, read_only): |
| self._AddGetter(attribute, html_name) |
| if not read_only: |
| self._AddSetter(attribute, html_name) |
| def _AddGetter(self, attr, html_name): |
| type_info = self._TypeInfo(attr.type.id) |
| - dart_declaration = '%s get %s' % (SecureOutputType(self, attr.type.id), html_name) |
| + dart_declaration = '%s get %s' % (self.SecureOutputType(attr.type.id), html_name) |
|
vsm
2012/11/07 22:31:28
length
blois
2012/11/08 00:08:34
Done.
|
| is_custom = 'Custom' in attr.ext_attrs or 'CustomGetter' in attr.ext_attrs |
| cpp_callback_name = self._GenerateNativeBinding(attr.id, 1, |
| dart_declaration, 'Getter', is_custom) |
| @@ -385,7 +384,7 @@ class DartiumBackend(HtmlDartGenerator): |
| self._members_emitter.Emit( |
| '\n' |
| ' $TYPE operator[](int index) native "$(INTERFACE)_item_Callback";\n', |
| - TYPE=SecureOutputType(self, element_type), INTERFACE=self._interface.id) |
| + TYPE=self.SecureOutputType(element_type), INTERFACE=self._interface.id) |
|
vsm
2012/11/07 22:31:28
length
blois
2012/11/08 00:08:34
Done.
|
| if self._HasNativeIndexSetter(): |
| self._EmitNativeIndexSetter(dart_element_type) |
| @@ -435,7 +434,7 @@ class DartiumBackend(HtmlDartGenerator): |
| 'NumericIndexedGetter' in ext_attrs) |
| def _EmitNativeIndexGetter(self, element_type): |
| - dart_declaration = '%s operator[](int index)' % SecureOutputType(self, element_type, True) |
| + dart_declaration = '%s operator[](int index)' % self.SecureOutputType(element_type, True) |
|
vsm
2012/11/07 22:31:28
length
blois
2012/11/08 00:08:34
Done.
|
| self._GenerateNativeBinding('numericIndexGetter', 2, dart_declaration, |
| 'Callback', True) |
| @@ -447,7 +446,7 @@ class DartiumBackend(HtmlDartGenerator): |
| self._GenerateNativeBinding('numericIndexSetter', 3, dart_declaration, |
| 'Callback', True) |
| - def AddOperation(self, info, html_name): |
| + def EmitOperation(self, info, html_name): |
| """ |
| Arguments: |
| info: An OperationInfo object. |
| @@ -461,7 +460,7 @@ class DartiumBackend(HtmlDartGenerator): |
| dart_declaration = '%s%s %s(%s)' % ( |
| 'static ' if info.IsStatic() else '', |
| - SecureOutputType(self, info.type_name), |
| + self.SecureOutputType(info.type_name), |
| html_name, |
| info.ParametersDeclaration( |
| (lambda x: 'dynamic') if needs_dispatcher else self._DartType)) |
| @@ -513,7 +512,7 @@ class DartiumBackend(HtmlDartGenerator): |
| dart_declaration = '%s%s _%s(%s)' % ( |
| 'static ' if operation.is_static else '', |
| - SecureOutputType(self, operation.type.id), overload_name, argument_list) |
| + self.SecureOutputType(operation.type.id), overload_name, argument_list) |
|
vsm
2012/11/07 22:31:28
length
blois
2012/11/08 00:08:34
Done.
|
| cpp_callback_name = self._GenerateNativeBinding( |
| overload_name, (0 if operation.is_static else 1) + argument_count, |
| dart_declaration, 'Callback', False) |