diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2006-05-07 09:01:59 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2006-05-07 09:01:59 +0200 |
commit | 93d0120c3f2ae70c4d7c1887f5418e235455c857 (patch) | |
tree | b0753cb252f7b07d30263e9edc8fdd282fadbbd4 /timers.c | |
parent | 452eec70a7194b57b3ae2653795af632e38c8f4e (diff) | |
download | vdr-93d0120c3f2ae70c4d7c1887f5418e235455c857.tar.gz vdr-93d0120c3f2ae70c4d7c1887f5418e235455c857.tar.bz2 |
Now using the event's start time when checking against VPS margin
Diffstat (limited to 'timers.c')
-rw-r--r-- | timers.c | 13 |
1 files changed, 8 insertions, 5 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: timers.c 1.58 2006/04/21 15:12:49 kls Exp $ + * $Id: timers.c 1.59 2006/05/07 09:01:00 kls Exp $ */ #include "timers.h" @@ -365,10 +365,13 @@ bool cTimer::Matches(time_t t, bool Directly, int Margin) const } if (HasFlags(tfActive)) { - if (HasFlags(tfVps) && !Directly && event && event->Vps() && event->Schedule() && event->Schedule()->PresentSeenWithin(30)) { - startTime = event->StartTime(); - stopTime = event->EndTime(); - return event->IsRunning(true); + if (HasFlags(tfVps) && event && event->Vps()) { + if (Margin || !Directly) { + startTime = event->StartTime(); + stopTime = event->EndTime(); + if (!Margin) + return event->IsRunning(true); + } } return startTime <= t + Margin && t < stopTime; // must stop *before* stopTime to allow adjacent timers } |