summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2003-08-17 08:58:02 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2003-08-17 08:58:02 +0200
commitb65687ebcfe79f8258bf3ca9ece057f16fae047b (patch)
tree6695894de09bb900f3b424805d47c8dab339c03d
parent3a27bdfeda2a0de7e1c4b3f7f15925e4448e8f72 (diff)
downloadvdr-b65687ebcfe79f8258bf3ca9ece057f16fae047b.tar.gz
vdr-b65687ebcfe79f8258bf3ca9ece057f16fae047b.tar.bz2
Made the "Zap timeout" a setup variable
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY3
-rw-r--r--MANUAL3
-rw-r--r--config.c5
-rw-r--r--config.h3
-rw-r--r--i18n.c19
-rw-r--r--menu.c3
-rw-r--r--vdr.c5
8 files changed, 35 insertions, 7 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 32d03857..a1097e26 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -457,6 +457,7 @@ Jürgen Zimmermann <jnzimmer@informatik.uni-kl.de>
Helmut Auer <vdr@helmutauer.de>
for reporting a superfluous error message in cLockFile
+ for suggesting to make the "Zap timeout" a setup variable
Jeremy Hall <jhall@UU.NET>
for fixing an incomplete initialization of the filter parameters in eit.c
diff --git a/HISTORY b/HISTORY
index 25b55955..5622eb70 100644
--- a/HISTORY
+++ b/HISTORY
@@ -2309,3 +2309,6 @@ Video Disk Recorder Revision History
Richard Robson for reporting this one).
- Fixed toggling channels with the '0' key (thanks to Mirko Günther for reporting
this one).
+- Made the "Zap timeout" (the time until a channel counts as "previous" for
+ switching with '0') a setup variable, available in "Setup/Miscellaneous"
+ (suggested by Helmut Auer).
diff --git a/MANUAL b/MANUAL
index 46389af8..3abf7eef 100644
--- a/MANUAL
+++ b/MANUAL
@@ -635,6 +635,9 @@ Version 1.2
connection after which the connection is automatically
closed. Default is 300, a value of 0 means no timeout.
+ Zap Timeout = 3 The time (in seconds) until a channel counts as "previous"
+ for switching with '0'
+
* Executing system commands
The "VDR" menu option "Commands" allows you to execute any system commands
diff --git a/config.c b/config.c
index 8a30d3c1..924a70ed 100644
--- a/config.c
+++ b/config.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: config.c 1.114 2003/05/11 13:50:02 kls Exp $
+ * $Id: config.c 1.115 2003/08/17 08:47:41 kls Exp $
*/
#include "config.h"
@@ -262,6 +262,7 @@ cSetup::cSetup(void)
EPGScanTimeout = 5;
EPGBugfixLevel = 2;
SVDRPTimeout = 300;
+ ZapTimeout = 3;
SortTimers = 1;
PrimaryLimit = 0;
DefaultPriority = 50;
@@ -413,6 +414,7 @@ bool cSetup::Parse(const char *Name, const char *Value)
else if (!strcasecmp(Name, "EPGScanTimeout")) EPGScanTimeout = atoi(Value);
else if (!strcasecmp(Name, "EPGBugfixLevel")) EPGBugfixLevel = atoi(Value);
else if (!strcasecmp(Name, "SVDRPTimeout")) SVDRPTimeout = atoi(Value);
+ else if (!strcasecmp(Name, "ZapTimeout")) ZapTimeout = atoi(Value);
else if (!strcasecmp(Name, "SortTimers")) SortTimers = atoi(Value);
else if (!strcasecmp(Name, "PrimaryLimit")) PrimaryLimit = atoi(Value);
else if (!strcasecmp(Name, "DefaultPriority")) DefaultPriority = atoi(Value);
@@ -462,6 +464,7 @@ bool cSetup::Save(void)
Store("EPGScanTimeout", EPGScanTimeout);
Store("EPGBugfixLevel", EPGBugfixLevel);
Store("SVDRPTimeout", SVDRPTimeout);
+ Store("ZapTimeout", ZapTimeout);
Store("SortTimers", SortTimers);
Store("PrimaryLimit", PrimaryLimit);
Store("DefaultPriority", DefaultPriority);
diff --git a/config.h b/config.h
index c4590a77..f7eb28eb 100644
--- a/config.h
+++ b/config.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: config.h 1.167 2003/08/16 09:08:33 kls Exp $
+ * $Id: config.h 1.168 2003/08/17 08:46:34 kls Exp $
*/
#ifndef __CONFIG_H
@@ -219,6 +219,7 @@ public:
int EPGScanTimeout;
int EPGBugfixLevel;
int SVDRPTimeout;
+ int ZapTimeout;
int SortTimers;
int PrimaryLimit;
int DefaultPriority, DefaultLifetime;
diff --git a/i18n.c b/i18n.c
index 0363e9f1..253e2783 100644
--- a/i18n.c
+++ b/i18n.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: i18n.c 1.129 2003/07/13 15:03:07 kls Exp $
+ * $Id: i18n.c 1.130 2003/08/17 08:53:24 kls Exp $
*
* Translations provided by:
*
@@ -2663,6 +2663,23 @@ const tI18nPhrase Phrases[] = {
"SVDRP Timeout (s)",
"SVDRP Timeout (s)",
},
+ { "Setup.Miscellaneous$Zap timeout (s)",
+ "Zap Timeout (s)",
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ "",// TODO
+ },
// The days of the week:
{ "MTWTFSS",
"MDMDFSS",
diff --git a/menu.c b/menu.c
index 9531d5bb..e3b32072 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.267 2003/08/16 13:12:26 kls Exp $
+ * $Id: menu.c 1.268 2003/08/17 08:52:07 kls Exp $
*/
#include "menu.h"
@@ -2256,6 +2256,7 @@ cMenuSetupMisc::cMenuSetupMisc(void)
Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$Min. event timeout (min)"), &data.MinEventTimeout));
Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$Min. user inactivity (min)"), &data.MinUserInactivity));
Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$SVDRP timeout (s)"), &data.SVDRPTimeout));
+ Add(new cMenuEditIntItem( tr("Setup.Miscellaneous$Zap timeout (s)"), &data.ZapTimeout));
}
// --- cMenuSetupPluginItem --------------------------------------------------
diff --git a/vdr.c b/vdr.c
index e10d9a31..48ed6277 100644
--- a/vdr.c
+++ b/vdr.c
@@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
- * $Id: vdr.c 1.164 2003/08/16 15:21:35 kls Exp $
+ * $Id: vdr.c 1.165 2003/08/17 08:50:25 kls Exp $
*/
#include <getopt.h>
@@ -57,7 +57,6 @@
#define ACTIVITYTIMEOUT 60 // seconds before starting housekeeping
#define SHUTDOWNWAIT 300 // seconds to wait in user prompt before automatic shutdown
#define MANUALSTART 600 // seconds the next timer must be in the future to assume manual start
-#define ZAPTIMEOUT 3 // seconds until a channel counts as "previous" for switching with '0'
static int Interrupted = 0;
@@ -500,7 +499,7 @@ int main(int argc, char *argv[])
LastChannel = cDevice::CurrentChannel();
LastChannelChanged = time(NULL);
}
- if (time(NULL) - LastChannelChanged >= ZAPTIMEOUT && LastChannel != PreviousChannel[0] && LastChannel != PreviousChannel[1])
+ if (time(NULL) - LastChannelChanged >= Setup.ZapTimeout && LastChannel != PreviousChannel[0] && LastChannel != PreviousChannel[1])
PreviousChannel[PreviousChannelIndex ^= 1] = LastChannel;
// Timers and Recordings:
if (!Timers.BeingEdited()) {