From 9bb563148acaa6198c21d333844471c7c90c4fd7 Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Wed, 18 Aug 2010 17:06:05 +0200 Subject: [PATCH] TaskView: correctly pop-up aborted/failed notifications in foreground --- lib/python/Screens/TaskView.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/python/Screens/TaskView.py b/lib/python/Screens/TaskView.py index 7864860..660fb27 100644 --- a/lib/python/Screens/TaskView.py +++ b/lib/python/Screens/TaskView.py @@ -117,7 +117,7 @@ class JobView(InfoBarNotifications, Screen, ConfigListScreen): self["config"].hide() if self.settings.afterEvent.getValue() == "nothing": return - elif self.settings.afterEvent.getValue() == "close": + elif self.settings.afterEvent.getValue() == "close" and self.job.status == self.job.FINISHED: self.close(False) from Screens.MessageBox import MessageBox if self.settings.afterEvent.getValue() == "deepstandby": @@ -127,6 +127,12 @@ class JobView(InfoBarNotifications, Screen, ConfigListScreen): 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 checkNotifications(self): + InfoBarNotifications.checkNotifications(self) + if Notifications.notifications == []: + if self.settings.afterEvent.getValue() == "close" and self.job.status == self.job.FAILED: + self.close(False) + def sendStandbyNotification(self, answer): if answer: Notifications.AddNotification(Screens.Standby.Standby) -- 2.7.4