def apply(self, ui): logging.debug(self.movement) if self.movement == 'last': ui.current_buffer.focus_last() ui.update() else: MoveCommand.apply(self, ui)
def apply(self, ui): logging.debug(self.movement) tbuffer = ui.current_buffer if self.movement == 'parent': tbuffer.focus_parent() elif self.movement == 'first reply': tbuffer.focus_first_reply() elif self.movement == 'last reply': tbuffer.focus_last_reply() elif self.movement == 'next sibling': tbuffer.focus_next_sibling() elif self.movement == 'previous sibling': tbuffer.focus_prev_sibling() elif self.movement == 'next': tbuffer.focus_next() elif self.movement == 'previous': tbuffer.focus_prev() elif self.movement == 'next unfolded': tbuffer.focus_next_unfolded() elif self.movement == 'previous unfolded': tbuffer.focus_prev_unfolded() else: MoveCommand.apply(self, ui) # TODO add 'next matching' if threadbuffer stores the original query # TODO: add next by date.. tbuffer.body.refresh()