implement device shutdown on deletion or lack of profiles

This commit is contained in:
Jakob Ketterl
2021-03-18 22:59:46 +01:00
parent f1619b81fe
commit c50473fea5
7 changed files with 39 additions and 12 deletions

View File

@ -122,6 +122,10 @@ class ServiceHandler(SdrSourceEventClient):
logger.debug("sdr source failed; stopping services.")
self.stopServices()
def onShutdown(self):
logger.debug("sdr source is shutting down; shutting down service handler, too.")
self.shutdown()
def onEnable(self):
self._scheduleServiceStartup()

View File

@ -258,6 +258,9 @@ class ServiceScheduler(SdrSourceEventClient):
def onFail(self):
self.shutdown()
def onShutdown(self):
self.shutdown()
def onDisable(self):
self.cancelTimer()