summaryrefslogtreecommitdiff
path: root/config.c
diff options
context:
space:
mode:
authorMidas <vdrportal_midas@gmx.de>2010-06-08 12:52:10 +0200
committerMidas <vdrportal_midas@gmx.de>2010-06-08 12:52:10 +0200
commit891bfb5ba9f052f9a97ef0abedeb039236701755 (patch)
tree839838706677c12ff9f0b9a6a1ee0bdd5926fba3 /config.c
parent4753e96fbaaf0ac96ea8a8512e90819591cdc723 (diff)
downloadvdr-plugin-block-891bfb5ba9f052f9a97ef0abedeb039236701755.tar.gz
vdr-plugin-block-891bfb5ba9f052f9a97ef0abedeb039236701755.tar.bz2
This version completes the basic parental guidance
functions. I will update README soon.
Diffstat (limited to 'config.c')
-rw-r--r--config.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/config.c b/config.c
index b311fd2..e3937ad 100644
--- a/config.c
+++ b/config.c
@@ -13,19 +13,28 @@
cSetupBlock SetupBlock;
int cSetupBlock::LastChannel=0;
+int cSetupBlock::DetectionMethod=0;
+int cSetupBlock::OkAllowed=1;
cSetupBlock::cSetupBlock(void):
- HideMenuEntry(0),
- MessageTimeout(2),
- DetectionMethod(0)
+ HideMenuEntry(0),
+ MessageTimeout(2),
+ ExtraOptionsVisible(1)
{
}
bool cSetupBlock::Parse(const char *Name, const char *Value)
{
if (strcmp(Name, "HideMenuEntry") == 0) HideMenuEntry = atoi(Value);
- else if (strcmp(Name, "MessageTimeout") == 0) MessageTimeout = atoi(Value);
- else if (strcmp(Name, "DetectionMethod") == 0) DetectionMethod = atoi(Value);
- else return false;
+ else if (strcmp(Name, "MessageTimeout") == 0) MessageTimeout = atoi(Value);
+ else if (strcmp(Name, "DetectionMethod") == 0) DetectionMethod = atoi(Value);
+
+ //if you want to make use of the following you have to manually add Block.ExtraOptionsVisible to your setup.conf
+ //0 means options 'Detection Method' and 'Ok temporarily deblocks' are not visible (eg for parental guidance)
+ //1 means the options are visible in the setup of vdr and everybody could alter the values
+ else if (strcmp(Name, "ExtraOptionsVisible") == 0) ExtraOptionsVisible = atoi(Value);
+
+ else if (strcmp(Name, "OkAllowed")==0) OkAllowed = atoi(Value);
+ else return false;
return true;
}