- Notifications.AddNotificationWithCallback(self.standby, MessageBox, _("A sleep timer want's to set your\nDreambox to standby. Do that now?"), timeout = 20)
+ if config.SleepTimer.ask.value and not Screens.Standby.inStandby:
+ Notifications.AddNotificationWithCallback(self.standby, MessageBox, _("A sleep timer wants to set your\nDreambox to standby. Do that now?"), timeout = 20)
else:
self.standby(True)
else:
self.standby(True)
@@ -40,36+42,33 @@ class SleepTimerEntry(timer.TimerEntry):
def shutdown(self, answer):
if answer is not None:
def shutdown(self, answer):
if answer is not None:
- if answer:
- quitMainloop(1)
+ if answer and not Screens.Standby.inTryQuitMainloop: