diff options
-rw-r--r-- | display.c | 9 | ||||
-rw-r--r-- | plugin.c | 11 |
2 files changed, 12 insertions, 8 deletions
@@ -31,7 +31,7 @@ #include <vdr/remote.h> cGraphLCDDisplay::cGraphLCDDisplay() -: cThread("glcd_display"), +: cThread("graphlcd_display"), mLcd(NULL), mScreen(NULL), mSkin(NULL), @@ -60,6 +60,8 @@ cGraphLCDDisplay::cGraphLCDDisplay() cGraphLCDDisplay::~cGraphLCDDisplay() { + Cancel(3); + delete mSkin; delete mSkinConfig; delete mScreen; @@ -68,11 +70,6 @@ cGraphLCDDisplay::~cGraphLCDDisplay() delete mService; } -void cGraphLCDDisplay::Stop (void) -{ - Cancel(3); -} - bool cGraphLCDDisplay::Initialise(GLCD::cDriver * Lcd, const std::string & CfgPath, const std::string & SkinsPath, const std::string & SkinName) { std::string skinsPath; @@ -93,6 +93,7 @@ public: virtual bool ProcessArgs(int argc, char * argv[]); virtual bool Initialize(); virtual bool Start(); + virtual void Stop(void); virtual void Housekeeping(); virtual const char **SVDRPHelpPages(void); virtual cString SVDRPCommand(const char *Command, const char *Option, int &ReplyCode); @@ -120,12 +121,18 @@ cPluginGraphLCD::cPluginGraphLCD() cPluginGraphLCD::~cPluginGraphLCD() { - for (unsigned int index = 0; index < GRAPHLCD_MAX_DISPLAYS; index++) - DisconnectDisplay(index); mExtData->ReleaseExtData(); mExtData = NULL; } +void cPluginGraphLCD::Stop(void) +{ + for (unsigned int index = 0; index < GRAPHLCD_MAX_DISPLAYS; index++) { + dsyslog("graphlcd plugin: DisconnectDisplay %d", index); + DisconnectDisplay(index); + }; +} + const char * cPluginGraphLCD::CommandLineHelp() { return " -c, --config=CFG use CFG as driver config file (default is \"" PLUGIN_GRAPHLCDCONF "\")\n" |