Commit Message
Anssi Kolehmainen wrote:
> Hi,
>
> In YLE channels (in Finland) there are gaps between programs (in
> EPG-data) and yaepg draws only first program and then 'No Info' bar even
> when there are more programs.
>
> Attached is a small patch for yaepg-0.0.2 which adds code to search for
> next program. It also changes granularity for text box drawing from 5
> minutes to 1 minute because YLE has some 4:30min programs (which are
> drawn as thin lines if granularity is 5min).
> Finally it changes font from fontYaepg to fontSml which looks much
> better with my Nova-T and xine-lib.
This one gives an european flavour to the dates
Bye
@@ -780,24 +780,8 @@
cDateBox::cDateBox(time_t time)
:cTextBox(DTBOX_WIDTH, DTBOX_HEIGHT, lightgrey, tint, fontDateBox)
{
- char dateStr[30];
- date = time;
- (void) localtime_r(&date, &dateTm);
-
SetXAlign(TBOX_TXT_CENTER);
- if (iTimeFormat == TIME_24HR) {
- snprintf(dateStr, 30, "%02d:%02d %s %d/%d/%d",
- dateTm.tm_hour, dateTm.tm_min,
- tr(numToDay[dateTm.tm_wday]), dateTm.tm_mon+1,
- dateTm.tm_mday, dateTm.tm_year+1900);
- }
- else {
- snprintf(dateStr, 30, "%2d:%02d %s %s %d/%d/%d",
- FMT_12HR(dateTm.tm_hour), dateTm.tm_min,
- FMT_AMPM(dateTm.tm_hour), tr(numToDay[dateTm.tm_wday]),
- dateTm.tm_mon+1, dateTm.tm_mday, dateTm.tm_year+1900);
- }
- SetText(1, dateStr);
+ SetText(1, *DayDateTime());
}
cDateBox::~cDateBox()
@@ -1410,7 +1394,7 @@
datebox->SetXAlign(TBOX_TXT_CENTER);
char dateStr[16];
if (currChan == 0) {
- snprintf(dateStr, 16, "%d/%d", startTime.tm_mon+1, startTime.tm_mday);
+ snprintf(dateStr, 16, "%d/%d", startTime.tm_mday, startTime.tm_mon+1);
}
else {
snprintf(dateStr, 16, "%d-", currChan);