SleepTimerEdit: Made the previous commit a bit less complicated
authorLittlesat <littlesat99@yahoo.com>
Fri, 1 Mar 2013 15:38:16 +0000 (16:38 +0100)
committerLittlesat <littlesat99@yahoo.com>
Fri, 1 Mar 2013 15:38:16 +0000 (16:38 +0100)
Sorry I copied the incorrect file previously...

lib/python/Screens/SleepTimerEdit.py

index 9312a95..3108aa3 100644 (file)
@@ -73,11 +73,10 @@ class SleepTimerEdit(ConfigListScreen, Screen):
                        if self["config"].isChanged():
                                self.session.openWithCallback(self.cancel, MessageBox, _("Really close without saving settings?"))
                        else:
-                               answer = True
+                               self.close()
                elif answer:
-                       if self["config"].isChanged():
-                               for x in self["config"].list:
-                                       x[1].cancel()
+                       for x in self["config"].list:
+                               x[1].cancel()
                        self.close()
 
        def getCurrentEntry(self):