diff options
author | louis <louis.braun@gmx.de> | 2013-05-24 16:23:23 +0200 |
---|---|---|
committer | louis <louis.braun@gmx.de> | 2013-05-24 16:23:23 +0200 |
commit | 9f47ab764efc83d8bf94f25c4badeb6e4c91c649 (patch) | |
tree | d919adf7613949f0107b968c2bf13736075c17fc /timer.c | |
parent | c611e004582067640111ef2f023410025201157d (diff) | |
download | vdr-plugin-tvguide-9f47ab764efc83d8bf94f25c4badeb6e4c91c649.tar.gz vdr-plugin-tvguide-9f47ab764efc83d8bf94f25c4badeb6e4c91c649.tar.bz2 |
Version 0.0.4
Diffstat (limited to 'timer.c')
-rw-r--r-- | timer.c | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -15,7 +15,11 @@ void cMyTime::Now() { t = time(0);
tStart = t;
tStart = GetRounded();
- tEnd = tStart + (tvguideConfig.osdHeight - tvguideConfig.statusHeaderHeight - tvguideConfig.headerHeight - tvguideConfig.footerHeight)/tvguideConfig.minuteHeight*60;
+ if (tvguideConfig.displayMode == eVertical) {
+ tEnd = tStart + (tvguideConfig.osdHeight - tvguideConfig.statusHeaderHeight - tvguideConfig.channelHeaderHeight - tvguideConfig.footerHeight)/tvguideConfig.minutePixel*60;
+ } else if (tvguideConfig.displayMode == eHorizontal) {
+ tEnd = tStart + (tvguideConfig.osdWidth - tvguideConfig.channelHeaderWidth)/tvguideConfig.minutePixel*60;
+ }
}
void cMyTime::AddStep(int step) {
@@ -34,7 +38,11 @@ bool cMyTime::DelStep(int step) { void cMyTime::SetTime(time_t newTime) {
tStart = newTime;
- tEnd = tStart + (tvguideConfig.osdHeight - tvguideConfig.statusHeaderHeight - tvguideConfig.headerHeight - tvguideConfig.footerHeight)/tvguideConfig.minuteHeight*60;
+ if (tvguideConfig.displayMode == eVertical) {
+ tEnd = tStart + (tvguideConfig.osdHeight - tvguideConfig.statusHeaderHeight - tvguideConfig.channelHeaderHeight - tvguideConfig.footerHeight)/tvguideConfig.minutePixel*60;
+ } else if (tvguideConfig.displayMode == eHorizontal) {
+ tEnd = tStart + (tvguideConfig.osdWidth - tvguideConfig.channelHeaderWidth)/tvguideConfig.minutePixel*60;
+ }
}
time_t cMyTime::getPrevPrimetime(time_t current) {
|