diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2004-05-16 10:35:36 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2004-05-16 10:35:36 +0200 |
commit | 5d99df7b7760c4a2b497c737a15b609008f6d56d (patch) | |
tree | a342f2f7465a73fe2bd63848d87566af8d646dd3 /config.c | |
parent | 7aab06d8b1c6de59d06756d44c631984acd299b3 (diff) | |
download | vdr-5d99df7b7760c4a2b497c737a15b609008f6d56d.tar.gz vdr-5d99df7b7760c4a2b497c737a15b609008f6d56d.tar.bz2 |
Implemented 'skins' and 'themes'
Diffstat (limited to 'config.c')
-rw-r--r-- | config.c | 29 |
1 files changed, 22 insertions, 7 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: config.c 1.125 2004/02/28 11:12:20 kls Exp $ + * $Id: config.c 1.126 2004/05/16 10:08:09 kls Exp $ */ #include "config.h" @@ -245,6 +245,8 @@ cSetup Setup; cSetup::cSetup(void) { OSDLanguage = 0; + strcpy(OSDSkin, "sttng"); + strcpy(OSDTheme, "default"); PrimaryDVB = 1; ShowInfoOnChSwitch = 1; MenuScrollPage = 1; @@ -279,9 +281,12 @@ cSetup::cSetup(void) UpdateChannels = 4; RecordDolbyDigital = 1; ChannelInfoPos = 0; - OSDwidth = 52; - OSDheight = 18; + OSDLeft = 54; + OSDTop = 45; + OSDWidth = 624; + OSDHeight = 486; OSDMessageTime = 1; + UseSmallFont = 1; MaxVideoFileSize = MAXVIDEOFILESIZE; SplitEditedFiles = 0; MinEventTimeout = 30; @@ -392,6 +397,8 @@ bool cSetup::ParseLanguages(const char *Value, int *Values) bool cSetup::Parse(const char *Name, const char *Value) { if (!strcasecmp(Name, "OSDLanguage")) OSDLanguage = atoi(Value); + else if (!strcasecmp(Name, "OSDSkin")) strn0cpy(OSDSkin, Value, MaxSkinName); + else if (!strcasecmp(Name, "OSDTheme")) strn0cpy(OSDTheme, Value, MaxThemeName); else if (!strcasecmp(Name, "PrimaryDVB")) PrimaryDVB = atoi(Value); else if (!strcasecmp(Name, "ShowInfoOnChSwitch")) ShowInfoOnChSwitch = atoi(Value); else if (!strcasecmp(Name, "MenuScrollPage")) MenuScrollPage = atoi(Value); @@ -426,9 +433,12 @@ bool cSetup::Parse(const char *Name, const char *Value) else if (!strcasecmp(Name, "UpdateChannels")) UpdateChannels = atoi(Value); else if (!strcasecmp(Name, "RecordDolbyDigital")) RecordDolbyDigital = atoi(Value); else if (!strcasecmp(Name, "ChannelInfoPos")) ChannelInfoPos = atoi(Value); - else if (!strcasecmp(Name, "OSDwidth")) OSDwidth = atoi(Value); - else if (!strcasecmp(Name, "OSDheight")) OSDheight = atoi(Value); + else if (!strcasecmp(Name, "OSDLeft")) OSDLeft = atoi(Value); + else if (!strcasecmp(Name, "OSDTop")) OSDTop = atoi(Value); + else if (!strcasecmp(Name, "OSDWidth")) { OSDWidth = atoi(Value); if (OSDWidth < 100) OSDWidth *= 12; OSDWidth &= ~0x07; } // OSD width must be a multiple of 8 + else if (!strcasecmp(Name, "OSDHeight")) { OSDHeight = atoi(Value); if (OSDHeight < 100) OSDHeight *= 27; } else if (!strcasecmp(Name, "OSDMessageTime")) OSDMessageTime = atoi(Value); + else if (!strcasecmp(Name, "UseSmallFont")) UseSmallFont = atoi(Value); else if (!strcasecmp(Name, "MaxVideoFileSize")) MaxVideoFileSize = atoi(Value); else if (!strcasecmp(Name, "SplitEditedFiles")) SplitEditedFiles = atoi(Value); else if (!strcasecmp(Name, "MinEventTimeout")) MinEventTimeout = atoi(Value); @@ -446,6 +456,8 @@ bool cSetup::Parse(const char *Name, const char *Value) bool cSetup::Save(void) { Store("OSDLanguage", OSDLanguage); + Store("OSDSkin", OSDSkin); + Store("OSDTheme", OSDTheme); Store("PrimaryDVB", PrimaryDVB); Store("ShowInfoOnChSwitch", ShowInfoOnChSwitch); Store("MenuScrollPage", MenuScrollPage); @@ -480,9 +492,12 @@ bool cSetup::Save(void) Store("UpdateChannels", UpdateChannels); Store("RecordDolbyDigital", RecordDolbyDigital); Store("ChannelInfoPos", ChannelInfoPos); - Store("OSDwidth", OSDwidth); - Store("OSDheight", OSDheight); + Store("OSDLeft", OSDLeft); + Store("OSDTop", OSDTop); + Store("OSDWidth", OSDWidth); + Store("OSDHeight", OSDHeight); Store("OSDMessageTime", OSDMessageTime); + Store("UseSmallFont", UseSmallFont); Store("MaxVideoFileSize", MaxVideoFileSize); Store("SplitEditedFiles", SplitEditedFiles); Store("MinEventTimeout", MinEventTimeout); |