UI Mode: Add 'g' and 'G'

This commit is contained in:
Brian Buller 2019-02-25 07:44:42 -06:00
parent 7c0edd1871
commit 427468c6a8
2 changed files with 6 additions and 5 deletions

View File

@ -182,6 +182,12 @@ func (screen *MainScreen) handleKeyEvent(event termbox.Event) int {
} else if event.Ch == 'k' || event.Key == termbox.KeyArrowUp {
screen.moveCursorUp()
} else if event.Ch == 'G' {
screen.cursor[screen.currentList] = len(*screen.displayList) - 1
} else if event.Ch == 'g' {
screen.cursor[screen.currentList] = 0
} else if event.Ch == '/' {
screen.startFilter()

View File

@ -78,11 +78,6 @@ func (a *AppState) opToggleTaskComplete(args []string) int {
}
func (a *AppState) opArchiveTasks(args []string) int {
if err := app.LoadDoneList(); err != nil {
fmt.Println("Error loading 'Done' list")
fmt.Println(err.Error())
return 1
}
if len(args) > 0 {
for _, v := range args {
var id int