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 *
#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):