Fixed issue with LinphoneStatus in python wrapper

This commit is contained in:
Sylvain Berfini 2017-07-11 14:46:39 +02:00
parent 5b09936389
commit 9d15a75723

View file

@ -214,7 +214,7 @@ class ArgumentType:
"""
self.fmt_str = 'd'
self.cfmt_str = '%f'
elif self.basic_type == 'bool_t':
elif self.basic_type == 'bool_t' or self.basic_type == 'LinphoneStatus':
self.type_str = 'bool'
self.check_condition = "!PyBool_Check({arg_name})"
self.convert_code = "{result_name}{result_suffix} = {cast}PyObject_IsTrue({arg_name});\n"
@ -1042,7 +1042,7 @@ class EventCallbackMethodDefinition(MethodDefinition):
class LinphoneModule(object):
def __init__(self, tree, blacklisted_classes, blacklisted_events, blacklisted_functions, hand_written_codes):
self.known_types = ['char', 'int', 'int8_t', 'int16_t', 'int32_t', 'int64_t', 'uint8_t', 'uint16_t', 'uint32_t', 'uint64_t', 'bool_t', 'float', 'double', 'size_t', 'time_t', 'MSList', 'bctbx_list_t', 'MSVideoSize', 'LCSipTransports', 'PayloadType']
self.known_types = ['char', 'int', 'int8_t', 'int16_t', 'int32_t', 'int64_t', 'uint8_t', 'uint16_t', 'uint32_t', 'uint64_t', 'bool_t', 'float', 'double', 'size_t', 'time_t', 'MSList', 'bctbx_list_t', 'MSVideoSize', 'LCSipTransports', 'PayloadType', 'LinphoneStatus']
self.internal_instance_method_names = ['destroy', 'ref', 'unref']
self.internal_property_names = ['user_data']
self.bctbxlist_types = set([])