+
+ def performAfterEvent(self):
+ self["config"].hide()
+ if self.settings.afterEvent.getValue() == "nothing":
+ return
+ elif self.settings.afterEvent.getValue() == "close":
+ self.abort()
+ from Screens.MessageBox import MessageBox
+ if self.settings.afterEvent.getValue() == "deepstandby":
+ if not Screens.Standby.inTryQuitMainloop:
+ Notifications.AddNotificationWithCallback(self.sendTryQuitMainloopNotification, MessageBox, _("A sleep timer wants to shut down\nyour Dreambox. Shutdown now?"), timeout = 20)
+ elif self.settings.afterEvent.getValue() == "standby":
+ if not Screens.Standby.inStandby:
+ Notifications.AddNotificationWithCallback(self.sendStandbyNotification, MessageBox, _("A sleep timer wants to set your\nDreambox to standby. Do that now?"), timeout = 20)
+
+ def sendStandbyNotification(self, answer):
+ if answer:
+ Notifications.AddNotification(Screens.Standby.Standby)
+
+ def sendTryQuitMainloopNotification(self, answer):
+ if answer:
+ Notifications.AddNotification(Screens.Standby.TryQuitMainloop, 1)