Mercurial > libervia-backend
comparison sat_frontends/jp/output_xmlui.py @ 2624:56f94936df1e
code style reformatting using black
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 27 Jun 2018 20:14:46 +0200 |
parents | 12bf089f0bf3 |
children | 003b8b4b56a7 |
comparison
equal
deleted
inserted
replaced
2623:49533de4540b | 2624:56f94936df1e |
---|---|
20 | 20 |
21 | 21 |
22 from sat_frontends.jp.constants import Const as C | 22 from sat_frontends.jp.constants import Const as C |
23 from sat_frontends.jp import xmlui_manager | 23 from sat_frontends.jp import xmlui_manager |
24 from sat.core.log import getLogger | 24 from sat.core.log import getLogger |
25 | |
25 log = getLogger(__name__) | 26 log = getLogger(__name__) |
26 | 27 |
27 | 28 |
28 __outputs__ = ["XMLUI"] | 29 __outputs__ = ["XMLUI"] |
29 | 30 |
32 """Outputs for XMLUI""" | 33 """Outputs for XMLUI""" |
33 | 34 |
34 def __init__(self, host): | 35 def __init__(self, host): |
35 self.host = host | 36 self.host = host |
36 host.register_output(C.OUTPUT_XMLUI, u"simple", self.xmlui, default=True) | 37 host.register_output(C.OUTPUT_XMLUI, u"simple", self.xmlui, default=True) |
37 host.register_output(C.OUTPUT_LIST_XMLUI, u"simple", self.xmlui_list, default=True) | 38 host.register_output( |
39 C.OUTPUT_LIST_XMLUI, u"simple", self.xmlui_list, default=True | |
40 ) | |
38 | 41 |
39 def xmlui(self, data): | 42 def xmlui(self, data): |
40 xmlui = xmlui_manager.create(self.host, data) | 43 xmlui = xmlui_manager.create(self.host, data) |
41 xmlui.show(values_only=True) | 44 xmlui.show(values_only=True) |
42 self.host.disp(u'') | 45 self.host.disp(u"") |
43 | 46 |
44 def xmlui_list(self, data): | 47 def xmlui_list(self, data): |
45 for d in data: | 48 for d in data: |
46 self.xmlui(d) | 49 self.xmlui(d) |