def __init__(self): self.help_text = ' n:Next N:Prev t:Play for time T:Go to time l:Play for lines L:Play to line a:Aggregate .:Repeat' self.screen = None self.quotebook = BookViewerBook() self.max_reverse = 100 self.quotebook_history = deque(maxlen=self.max_reverse) self.infile = [] self.curr_index = 0 self.last_skipped = 0 self.aggregate = False self.keys = { 'EXIT': 113, # q 'REPEAT': 46, # . 'PREVIOUS': 78, # N 'NEXT': 110, # n 'PLAY_FOR_TIME': 116, # t 'PLAY_TO_TIME': 84, # T 'PLAY_FOR_LINES': 108, # l 'PLAY_TO_LINE': 76, # L 'AGGREGATE': 97, # a 'ESCAPE': 27, # <ESC> }
def reset(self): self.quotebook = BookViewerBook() self.quotebook_history.clear() self.curr_index = 0
def reset(self): self.quotebook = BookViewerBook() self.quotebookHistory.clear() self.currIndex = -1