fix another timer-issue (with a try except-block... explanation is in the code)
authorStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Sat, 26 Nov 2005 05:45:16 +0000 (05:45 +0000)
committerStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Sat, 26 Nov 2005 05:45:16 +0000 (05:45 +0000)
RecordTimer.py

index 1340795..62fa637 100644 (file)
@@ -162,7 +162,12 @@ class RecordTimer(timer.Timer):
                        self.timeChanged(entry)
                elif entry.state != timer.TimerEntry.StateEnded:
                        entry.activate(timer.TimerEntry.EventAbort)
-                       self.timer_list.remove(entry)
+                       try: # FIXME: is needed, because after loading the timers, every timer (even already ended ones)
+                                # have the state EventWaiting..
+                               self.timer_list.remove(entry)
+                       except:
+                               pass
+                               
                        self.calcNextActivation()
                        print "timer did not yet start - removing"
                else: