kete: drop TuhiKeteShellWorker and directly use TuhiKeteShell
parent
5757bcfab1
commit
e4b0f9768d
|
@ -954,21 +954,6 @@ class TuhiKeteShell(cmd.Cmd):
|
||||||
print(f'\t\t* {d}: drawn on the {t}')
|
print(f'\t\t* {d}: drawn on the {t}')
|
||||||
|
|
||||||
|
|
||||||
class TuhiKeteShellWorker(Worker):
|
|
||||||
def __init__(self, manager):
|
|
||||||
super(TuhiKeteShellWorker, self).__init__(manager)
|
|
||||||
|
|
||||||
def start(self):
|
|
||||||
|
|
||||||
self.run()
|
|
||||||
|
|
||||||
self.stop()
|
|
||||||
|
|
||||||
def run(self):
|
|
||||||
self._shell = TuhiKeteShell(self.manager)
|
|
||||||
self._shell.run()
|
|
||||||
|
|
||||||
|
|
||||||
def parse(args):
|
def parse(args):
|
||||||
desc = 'Interactive commandline client to the Tuhi DBus daemon'
|
desc = 'Interactive commandline client to the Tuhi DBus daemon'
|
||||||
parser = argparse.ArgumentParser(description=desc)
|
parser = argparse.ArgumentParser(description=desc)
|
||||||
|
@ -987,8 +972,8 @@ def main(args):
|
||||||
|
|
||||||
try:
|
try:
|
||||||
with TuhiKeteManager() as mgr:
|
with TuhiKeteManager() as mgr:
|
||||||
worker = TuhiKeteShellWorker(mgr)
|
shell = TuhiKeteShell(mgr)
|
||||||
worker.start()
|
shell.run()
|
||||||
|
|
||||||
except DBusError as e:
|
except DBusError as e:
|
||||||
logger.error(e.message)
|
logger.error(e.message)
|
||||||
|
|
Loading…
Reference in New Issue