remove some unneeded debug output
[enigma2.git] / lib / python / Screens / TimerEdit.py
index ff2a017ffb6c014c0ec9a61404ebdcb77dcd087e..c0896f4107ff1953fddaba589e37dfed672dd0f7 100644 (file)
@@ -4,7 +4,6 @@ from Components.ActionMap import ActionMap
 from Components.TimeInput import TimeInput
 from Components.Label import Label
 from Components.Button import Button
-from Components.TextInput import TextInput
 from TimerEntry import TimerEntry
 from RecordTimer import RecordTimerEntry, parseEvent
 from time import *
@@ -49,8 +48,13 @@ class TimerEditList(Screen):
                #self.session.open(TimerEdit, self["timerlist"].getCurrent()[0])
                
        def removeTimer(self):
-               # FIXME doesn't work...
-               self.session.nav.RecordTimer.removeEntry(self["timerlist"].getCurrent()[0])
+               list = self["timerlist"]
+               currentIndex = list.getCurrentIndex()
+               list.moveDown()
+               if list.getCurrentIndex() == currentIndex:
+                       currentIndex -= 1
+                       list.moveToIndex(currentIndex)
+               self.session.nav.RecordTimer.removeEntry(list.getCurrent()[0])
                self.refill()
        
        def refill(self):