Fix 'gg' and 'dd' keypresses

This commit is contained in:
Caleb Bassi 2018-12-04 21:07:14 -08:00
parent db57b40659
commit 3dee8bc6f2
1 changed files with 6 additions and 3 deletions

View File

@ -296,7 +296,6 @@ func eventLoop() {
if previousKey == "g" {
proc.Top()
ui.Render(proc)
previousKey = ""
}
case "G", "<End>":
proc.Bottom()
@ -316,7 +315,6 @@ func eventLoop() {
case "d":
if previousKey == "d" {
proc.Kill()
previousKey = ""
}
case "<Tab>":
proc.Tab()
@ -325,7 +323,12 @@ func eventLoop() {
proc.ChangeSort(e)
ui.Render(proc)
}
previousKey = e.ID
if previousKey == e.ID {
previousKey = ""
} else {
previousKey = e.ID
}
}
}
}