X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/cd1a9f92f96bd60924795c88429acb7aba12e184..68c21083593b5b05681efaffbe6ec50aba385ddc:/lib/python/Components/TimerList.py diff --git a/lib/python/Components/TimerList.py b/lib/python/Components/TimerList.py index 81501ca8..da2ff949 100644 --- a/lib/python/Components/TimerList.py +++ b/lib/python/Components/TimerList.py @@ -2,6 +2,7 @@ from HTMLComponent import * from GUIComponent import * from Tools.FuzzyDate import FuzzyTime +import time from enigma import eListboxPythonMultiContent, eListbox, gFont from timer import TimerEntry @@ -25,8 +26,7 @@ RT_WRAP = 32 def TimerEntryComponent(timer, processed): res = [ timer ] - - res.append((0, 0, 400, 30, 0, RT_HALIGN_LEFT, timer.service_ref.getServiceName())) + res.append((0, 0, 220, 30, 0, RT_HALIGN_LEFT, timer.service_ref.getServiceName())) repeatedtext = "" days = [ "Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun" ] if (timer.repeated != 0): @@ -39,13 +39,11 @@ def TimerEntryComponent(timer, processed): repeatedtext += days[x] count += 1 flags = flags >> 1 - print [FuzzyTime(timer.begin)[1], FuzzyTime(timer.end)[1]] - print (FuzzyTime(timer.begin) + FuzzyTime(timer.end)[1:]) - res.append((0, 30, 200, 20, 1, RT_HALIGN_LEFT, repeatedtext + (" %s ... %s" % (FuzzyTime(timer.begin)[1], FuzzyTime(timer.end)[1])))) + res.append((0, 30, 300, 20, 1, RT_HALIGN_LEFT, repeatedtext + (" %s ... %s" % (FuzzyTime(timer.begin)[1], FuzzyTime(timer.end)[1])))) else: - res.append((0, 30, 200, 20, 1, RT_HALIGN_LEFT, repeatedtext + ("%s, %s ... %s" % (FuzzyTime(timer.begin) + FuzzyTime(timer.end)[1:])))) + res.append((0, 30, 300, 20, 1, RT_HALIGN_LEFT, repeatedtext + ("%s, %s ... %s" % (FuzzyTime(timer.begin) + FuzzyTime(timer.end)[1:])))) - res.append((300, 0, 200, 20, 1, RT_HALIGN_RIGHT, timer.description)) + res.append((240, 0, 320, 20, 1, RT_HALIGN_RIGHT, timer.name)) if not processed: if timer.state == TimerEntry.StateWait: @@ -59,7 +57,7 @@ def TimerEntryComponent(timer, processed): else: state = "done!" - res.append((300, 30, 200, 20, 1, RT_HALIGN_RIGHT, state)) + res.append((320, 30, 240, 20, 1, RT_HALIGN_RIGHT, state)) return res @@ -68,8 +66,8 @@ class TimerList(HTMLComponent, GUIComponent): GUIComponent.__init__(self) self.l = eListboxPythonMultiContent() self.l.setList(list) - self.l.setFont(0, gFont("Arial", 20)) - self.l.setFont(1, gFont("Arial", 18)) + self.l.setFont(0, gFont("Regular", 20)) + self.l.setFont(1, gFont("Regular", 18)) def getCurrent(self): return self.l.getCurrentSelection()