mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 00:11:14 +02:00
infoviewer: only show remaining time if time is set
This commit is contained in:
@@ -1750,10 +1750,12 @@ void CInfoViewer::show_Data (bool calledFromEvent)
|
||||
if (info_CurrentNext.flags & CSectionsdClient::epgflags::has_current) {
|
||||
int seit = (abs(jetzt - info_CurrentNext.current_zeit.startzeit) + 30) / 60;
|
||||
int rest = (info_CurrentNext.current_zeit.dauer / 60) - seit;
|
||||
if (jetzt < info_CurrentNext.current_zeit.startzeit) {
|
||||
runningPercent = 0;
|
||||
runningPercent = 0;
|
||||
if (!gotTime)
|
||||
snprintf(runningRest, sizeof(runningRest), "%d min", info_CurrentNext.current_zeit.dauer / 60);
|
||||
else if (jetzt < info_CurrentNext.current_zeit.startzeit)
|
||||
snprintf (runningRest, sizeof(runningRest), "in %d min", seit);
|
||||
} else {
|
||||
else {
|
||||
runningPercent = (jetzt - info_CurrentNext.current_zeit.startzeit) * 100 / info_CurrentNext.current_zeit.dauer;
|
||||
if (runningPercent > 100)
|
||||
runningPercent = 100;
|
||||
|
Reference in New Issue
Block a user