def __del__(self): self.clearDQueue() self.clearAAueue() if '0' == config.plugins.BoardReader.deleteIcons.value: removeAllIconsFromPath(config.plugins.BoardReader.SciezkaCache.value) print "iconmanager.py del Delete IconManager"
def save(self): for x in self["config"].list: x[1].save() configfile.save() if self.showcoverOld != config.plugins.BoardReader.showcover.value or \ self.SciezkaCacheOld != config.plugins.BoardReader.SciezkaCache.value: # remove files from old path removeAllIconsFromPath(self.SciezkaCacheOld)
def loadHistoryFromDisk(self): path = self.DOWNLOADED_IMAGE_PATH + "/" removeAllIconsFromPath(path) list = listdir(path) for item in list: if checkIconName(item): filePath = path + item if delta > 0 and delta <= getModifyDeltaDateInDays(filePath): try: removeFile(filePath) except: print("ERROR: while removing file %s" % filePath) else: self.queueAA.append(item)
def loadHistoryFromDisk(self): path = self.DOWNLOADED_IMAGE_PATH + "/" try: delta = int(config.plugins.BoardReader.deleteIcons.value) except: delta = -1 # check if we need to remove all old icons: if 0 == delta: removeAllIconsFromPath(path) list = listdir(path) for item in list: if checkIconName(item): filePath = path + item if delta > 0 and delta <= getModifyDeltaDateInDays(filePath): try: removeFile(filePath) except: print("ERROR: while removing file %s" % filePath) else: self.queueAA.append(item)
def __del__(self): self.clearDQueue() self.clearAAueue() removeAllIconsFromPath(self.DOWNLOADED_IMAGE_PATH)