summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY2
-rw-r--r--timers.c6
-rw-r--r--timers.h4
4 files changed, 8 insertions, 5 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 636cee9f..6f16b617 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -1560,6 +1560,7 @@ Nicolas Huillard <nhuillard@e-dition.fr>
Patrick Fischer <patrick_fischer@gmx.de>
for reporting an error in the cFilter example in PLUGINS.html
for making the static cControl functions thread safe
+ for suggesting that the cTimer constructor should take an optional cChannel
Ralf Müller <ralf@bj-ig.de>
for a patch that was used to implement cUnbufferedFile
diff --git a/HISTORY b/HISTORY
index dced2752..784ce6ec 100644
--- a/HISTORY
+++ b/HISTORY
@@ -4063,3 +4063,5 @@ Video Disk Recorder Revision History
- Fixed incrementing the 'state' variables in the repacker classes in remux.c
to avoid warnings with g++ 4.1.0 (reported by Ville Skyttä).
- The Makefile now reports a summary of failed plugins (thanks to Udo Richter).
+- The cTimer constructor can now take an optional cChannel (suggested by
+ Patrick Fischer).
diff --git a/timers.c b/timers.c
index c71d663f..bcf24336 100644
--- a/timers.c
+++ b/timers.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: timers.c 1.37 2005/12/27 14:33:14 kls Exp $
+ * $Id: timers.c 1.38 2006/01/01 15:41:46 kls Exp $
*/
#include "timers.h"
@@ -20,14 +20,14 @@
// -- cTimer -----------------------------------------------------------------
-cTimer::cTimer(bool Instant, bool Pause)
+cTimer::cTimer(bool Instant, bool Pause, cChannel *Channel)
{
startTime = stopTime = 0;
recording = pending = inVpsMargin = false;
flags = tfNone;
if (Instant)
SetFlags(tfActive | tfInstant);
- channel = Channels.GetByNumber(cDevice::CurrentChannel());
+ channel = Channel ? Channel : Channels.GetByNumber(cDevice::CurrentChannel());
time_t t = time(NULL);
struct tm tm_r;
struct tm *now = localtime_r(&t, &tm_r);
diff --git a/timers.h b/timers.h
index d3dfc843..b843d5ca 100644
--- a/timers.h
+++ b/timers.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: timers.h 1.20 2005/12/27 14:27:26 kls Exp $
+ * $Id: timers.h 1.21 2006/01/01 15:41:26 kls Exp $
*/
#ifndef __TIMERS_H
@@ -41,7 +41,7 @@ private:
char *summary;
const cEvent *event;
public:
- cTimer(bool Instant = false, bool Pause = false);
+ cTimer(bool Instant = false, bool Pause = false, cChannel *Channel = NULL);
cTimer(const cEvent *Event);
virtual ~cTimer();
cTimer& operator= (const cTimer &Timer);