diff options
author | anbr <vdr07@deltab.de> | 2010-12-21 20:55:19 +0100 |
---|---|---|
committer | anbr <vdr07@deltab.de> | 2010-12-21 20:55:19 +0100 |
commit | 2906f2d1b7e1c5931b3d05156569d6061eb6b9b5 (patch) | |
tree | ff3b3004b3f48d85a8b010097e82be8ed377237f /setup.h | |
parent | b8efd2c7861dfb6f55dff730d071e454d503a67d (diff) | |
download | vdr-plugin-dvdswitch-2906f2d1b7e1c5931b3d05156569d6061eb6b9b5.tar.gz vdr-plugin-dvdswitch-2906f2d1b7e1c5931b3d05156569d6061eb6b9b5.tar.bz2 |
release 0.1.4 from http://www.vdr-portal.de/board/thread.php?postid=845535#post8455350.1.4
Diffstat (limited to 'setup.h')
-rw-r--r-- | setup.h | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -3,6 +3,8 @@ #include <vdr/menuitems.h> +#define memberof(x) (sizeof(x)/sizeof(*x)) + class cDVDSwitchSetup { public: @@ -66,16 +68,15 @@ class cDVDSwitchSetup cDVDSwitchSetup(void); ~cDVDSwitchSetup(void); void Init(void); - bool SetupParse(const char *Name, const char *Value); - void Debug(void); + bool SetupParse(const char *Name, const char *Value, cImageList &ImageList); - void SetConfDir(char *value) + void SetConfDir(const char *value) { - strcpy(ConfigDirectory, value); - strcpy(DVDLink, ConfigDirectory); - strcat(DVDLink, "/dvdlink"); + strncpy(ConfigDirectory, value, memberof(ConfigDirectory)); + strncpy(DVDLink, ConfigDirectory, memberof(DVDLink)); + strncat(DVDLink, "/dvdlink", memberof(DVDLink)); } - void SetDVDDevice(char *value) { strcpy(DVDLinkOrg, value); } + void SetDVDDevice(const char *value) { strncpy(DVDLinkOrg, value, memberof(DVDLinkOrg)); } }; class cMenuSetupDVDSwitch : public cMenuSetupPage @@ -92,12 +93,13 @@ class cMenuSetupDVDSwitch : public cMenuSetupPage int ViewNavPos; bool ViewKey; int ViewKeyPos; + cImageList &ImageList; protected: void Set(void); virtual void Store(void); virtual eOSState ProcessKey(eKeys Key); public: - cMenuSetupDVDSwitch(void); + cMenuSetupDVDSwitch(cImageList &ImageList); }; class cMenuEditCatItem : public cOsdItem |