bridge, bridge constructor: fixed mix stuff

This commit is contained in:
Goffi 2011-01-30 22:54:58 +01:00
commit 894e276dec
2 changed files with 19 additions and 16 deletions

View file

@ -407,9 +407,11 @@ class DbusConstructor(Constructor):
if function["type"] == "method":
completion['debug'] = "" if not self.options.debug else 'debug ("%s")\n%s' % (section,8*' ')
completion['args_result'] = self.getArguments(function['sig_in'], name=arg_doc)
result = "self.db_%(category)s_iface.%(name)s(%(args_result)s)" % completion
completion['result'] = ("unicode(%s)" if self.options.unicode and function['sig_out'] == 's' else "%s") % result
methods_part.append("""\
def %(name)s(self, %(args)s):
%(debug)sreturn self.db_%(category)s_iface.%(name)s(%(args_result)s)
%(debug)sreturn %(result)s
""" % completion)
#at this point, methods_part should be filled,

View file

@ -161,6 +161,7 @@ sig_out=s
param_0_default="@DEFAULT@"
doc=Get real profile name from profile key
doc_param_0=%(doc_profile_key)s
doc_return=Real profile name, or empty string if the profile doesn't exist
[getProfilesList]
type=method