| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 """Generate template contexts of dictionaries for both v8 bindings and | 5 """Generate template contexts of dictionaries for both v8 bindings and |
| 6 implementation classes that are used by blink's core/modules. | 6 implementation classes that are used by blink's core/modules. |
| 7 """ | 7 """ |
| 8 | 8 |
| 9 import operator | 9 import operator |
| 10 from idl_types import IdlType | 10 from idl_types import IdlType |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 if member.default_value and not member.default_value.is_null: | 190 if member.default_value and not member.default_value.is_null: |
| 191 cpp_default_value = idl_type.literal_cpp_value(member.default_value) | 191 cpp_default_value = idl_type.literal_cpp_value(member.default_value) |
| 192 | 192 |
| 193 header_includes.update(idl_type.impl_includes_for_type(interfaces_info)) | 193 header_includes.update(idl_type.impl_includes_for_type(interfaces_info)) |
| 194 return { | 194 return { |
| 195 'cpp_default_value': cpp_default_value, | 195 'cpp_default_value': cpp_default_value, |
| 196 'cpp_name': cpp_name, | 196 'cpp_name': cpp_name, |
| 197 'getter_expression': getter_expression(), | 197 'getter_expression': getter_expression(), |
| 198 'has_method_expression': has_method_expression(), | 198 'has_method_expression': has_method_expression(), |
| 199 'has_method_name': has_method_name_for_dictionary_member(member), | 199 'has_method_name': has_method_name_for_dictionary_member(member), |
| 200 'is_nullable': idl_type.is_nullable, |
| 200 'is_traceable': idl_type.is_traceable, | 201 'is_traceable': idl_type.is_traceable, |
| 201 'member_cpp_type': member_cpp_type(), | 202 'member_cpp_type': member_cpp_type(), |
| 202 'null_setter_name': null_setter_name_for_dictionary_member(member), | 203 'null_setter_name': null_setter_name_for_dictionary_member(member), |
| 203 'rvalue_cpp_type': idl_type.cpp_type_args(used_as_rvalue_type=True), | 204 'rvalue_cpp_type': idl_type.cpp_type_args(used_as_rvalue_type=True), |
| 204 'setter_name': setter_name_for_dictionary_member(member), | 205 'setter_name': setter_name_for_dictionary_member(member), |
| 205 } | 206 } |
| OLD | NEW |