Skip to content

Commit

Permalink
[TimerEdit] show extended description in timers list
Browse files Browse the repository at this point in the history
  • Loading branch information
Dima73 authored and WanWizard committed Dec 29, 2019
1 parent ed15721 commit 624099e
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions lib/python/Screens/TimerEdit.py
Expand Up @@ -17,7 +17,7 @@
from time import time
from timer import TimerEntry as RealTimerEntry
from ServiceReference import ServiceReference
from enigma import eServiceReference
from enigma import eServiceReference, eEPGCache

class TimerEditList(Screen):
EMPTY = 0
Expand Down Expand Up @@ -164,8 +164,22 @@ def updateState(self):
else:
self["key_info"].setText(_("Info"))
text = cur.description
event = eEPGCache.getInstance().lookupEventId(cur.service_ref.ref, cur.eit)
if event:
ext_description = event.getExtendedDescription()
short_description = event.getShortDescription()
if text != short_description:
if text and short_description:
text = text + " [Timer]" + "\n" + short_description + " [EPG]"
elif short_description:
text = short_description
if ext_description and ext_description != text:
if text:
text += "\n" + ext_description
else:
text = ext_description
if not cur.conflict_detection:
text += _("\nConflict detection disabled!")
text += "\n" + _("\nConflict detection disabled!")

This comment has been minimized.

Copy link
@QuarkFermion

QuarkFermion Dec 31, 2019

Contributor

With longer extended descriptions it is possible that the warning "Conflict detection disabled!" will not be visible because of limited reserved space in UI (skin.xml). To make it visible at all times the warning text should be placed at the beginning of the description.

self["description"].setText(text)
stateRunning = cur.state in (1, 2)
if cur.state == 2 and self.key_red_choice != self.STOP:
Expand Down

0 comments on commit 624099e

Please sign in to comment.