summaryrefslogtreecommitdiff
path: root/menu.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2004-05-22 13:23:22 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2004-05-22 13:23:22 +0200
commit5aacc51c14491fa029f6408f45685bf505c606b5 (patch)
tree488ca1c1cadf5bf7123bfd359c3812af2946eec9 /menu.c
parentbcbb3137e7ae46a124c1d3af03d7be1b23f5846b (diff)
downloadvdr-5aacc51c14491fa029f6408f45685bf505c606b5.tar.gz
vdr-5aacc51c14491fa029f6408f45685bf505c606b5.tar.bz2
Single shot timers and events now show the day of week
Diffstat (limited to 'menu.c')
-rw-r--r--menu.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/menu.c b/menu.c
index 968a873c..f3b2eb1c 100644
--- a/menu.c
+++ b/menu.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: menu.c 1.300 2004/05/16 12:47:22 kls Exp $
+ * $Id: menu.c 1.302 2004/05/22 13:23:22 kls Exp $
*/
#include "menu.h"
@@ -633,6 +633,7 @@ eOSState cMenuEditTimer::ProcessKey(eKeys Key)
}
if (addIfConfirmed)
Timers.Add(timer);
+ timer->Matches();
Timers.Save();
isyslog("timer %d %s (%s)", timer->Index() + 1, addIfConfirmed ? "added" : "modified", timer->HasFlags(tfActive) ? "active" : "inactive");
addIfConfirmed = false;
@@ -677,9 +678,11 @@ bool cMenuTimerItem::operator< (const cListObject &ListObject)
void cMenuTimerItem::Set(void)
{
char *buffer = NULL;
- asprintf(&buffer, "%c\t%d\t%s\t%02d:%02d\t%02d:%02d\t%s",
+ asprintf(&buffer, "%c\t%d\t%s%s%s\t%02d:%02d\t%02d:%02d\t%s",
!(timer->HasFlags(tfActive)) ? ' ' : timer->FirstDay() ? '!' : timer->Recording() ? '#' : '>',
timer->Channel()->Number(),
+ timer->IsSingleEvent() ? WeekDayName(timer->StartTime()) : "",
+ timer->IsSingleEvent() ? " " : "",
timer->PrintDay(timer->Day()),
timer->Start() / 100,
timer->Start() % 100,
@@ -908,7 +911,7 @@ cMenuWhatsOnItem::cMenuWhatsOnItem(const cEvent *Event, cChannel *Channel)
char t = Timers.GetMatch(Event, &TimerMatch) ? (TimerMatch == tmFull) ? 'T' : 't' : ' ';
char v = event->Vps() && (event->Vps() - event->StartTime()) ? 'V' : ' ';
char r = event->IsRunning() ? '*' : ' ';
- asprintf(&buffer, "%d\t%.*s\t%.*s\t%c%c%c\t%s", channel->Number(), 6, channel->Name(), 5, event->GetTimeString(), t, v, r, event->Title());
+ asprintf(&buffer, "%d\t%.*s\t%s\t%c%c%c\t%s", channel->Number(), 6, channel->Name(), event->GetTimeString(), t, v, r, event->Title());
SetText(buffer, false);
}
@@ -1026,7 +1029,7 @@ cMenuScheduleItem::cMenuScheduleItem(const cEvent *Event)
char t = Timers.GetMatch(Event, &TimerMatch) ? (TimerMatch == tmFull) ? 'T' : 't' : ' ';
char v = event->Vps() && (event->Vps() - event->StartTime()) ? 'V' : ' ';
char r = event->IsRunning() ? '*' : ' ';
- asprintf(&buffer, "%.*s\t%.*s\t%c%c%c\t%s", 5, event->GetDateString(), 5, event->GetTimeString(), t, v, r, event->Title());
+ asprintf(&buffer, "%.*s\t%s\t%c%c%c\t%s", 6, event->GetDateString(), event->GetTimeString(), t, v, r, event->Title());
SetText(buffer, false);
}
@@ -1048,7 +1051,7 @@ public:
};
cMenuSchedule::cMenuSchedule(void)
-:cOsdMenu("", 6, 6, 4)
+:cOsdMenu("", 7, 6, 4)
{
now = next = false;
otherChannel = 0;