def procRESUME(self, workinglist = None, skipcheck = False): fulllist = utility.torrents["inactive"].keys() if workinglist is None: workinglist = fulllist else: workinglist = intersection(fulllist, workinglist) update = [1 for torrent in workinglist if torrent.actions.resume(skipcheck)] if update: utility.queue.updateAndInvoke(invokeLater = False)
def procPAUSE(self, workinglist = None, release = False): fulllist = utility.torrents["active"].keys() if workinglist is None: workinglist = fulllist else: workinglist = intersection(fulllist, workinglist) update = [1 for torrent in workinglist if torrent.actions.pause(release)] if update: utility.queue.UpdateRunningTorrentCounters()
def procUNSTOP(self, workinglist = None): fulllist = utility.torrents["inactive"].keys() if workinglist is None: workinglist = fulllist else: workinglist = intersection(fulllist, workinglist) update = [1 for torrent in workinglist if torrent.status.value == STATUS_STOP and torrent.actions.queue()] if update: utility.queue.updateAndInvoke()
def procQUEUE(self, workinglist = None): fulllist = utility.torrents["inactive"].keys() if workinglist is None: workinglist = fulllist else: workinglist = intersection(fulllist, workinglist) # if workinglist is None: # workinglist = utility.torrents["all"] update = [1 for torrent in workinglist if torrent.actions.queue()] if update: utility.queue.updateAndInvoke()