From c802ad0dd73d9f160979622b478ded333f09336b Mon Sep 17 00:00:00 2001 From: Martin Kolman Date: Sun, 2 Jan 2022 04:55:34 +0100 Subject: [PATCH] Remove message handling from the tracklogs module --- modules/mod_tracklog.py | 42 ----------------------------------------- 1 file changed, 42 deletions(-) diff --git a/modules/mod_tracklog.py b/modules/mod_tracklog.py index 2880057c..8ba99572 100644 --- a/modules/mod_tracklog.py +++ b/modules/mod_tracklog.py @@ -91,48 +91,6 @@ def firstTime(self): # eq, due to modRana or device crashing self._rescueLogs() - def handleMessage(self, message, messageType, args): - if message == "startLogging": - self.log.info("starting track logging") - # start a new log - if not self.loggingEnabled: - self.startLogging(self.get('logNameEntry', "")) - # or resume an existing one - elif self.loggingEnabled == True & self.loggingPaused == True: - self.log.info("resuming track logging") - self.loggingPaused = False - - elif message == "pauseLogging": - self.pauseLogging() - - elif message == "stopLogging": - self.log.info("stopping track logging") - self.stopLogging() - - elif message == 'nameInput': - entry = self.m.get('textEntry', None) - if entry is None: - self.log.error("error, text entry module is not loaded") - return - entryText = "" - logNameEntry = self.get('logNameEntry', None) - if logNameEntry: - entryText = logNameEntry - entry.entryBox(self, 'logNameEntry', 'Write tracklog name', entryText) - - elif message == 'clearTrace': - self.clearTrace() - - elif message == 'setupColorMenu': - m = self.m.get('showTracklogs', None) - if m: - m.setupChooseDistColorMenu('tracklog', '|tracklog:colorFromRegister|set:menu:None') - - elif message == 'colorFromRegister': - # set the color from the color register - colorName = self.get('distinctColorRegister', 'blue') - self.traceColor = colorName - def startLogging(self, name="", logType='gpx'): """Start a new log file