Use Home and End keys to navigate Top/Bottom.

This commit is contained in:
PanteR 2018-08-19 08:01:16 +03:00
parent fc56114b4f
commit 94e4cd8878

View File

@ -138,15 +138,19 @@ func (self *Proc) keyBinds() {
self.KeyPressed <- true
})
viKeys := []string{"j", "k", "gg", "G", "<C-d>", "<C-u>", "<C-f>", "<C-b>"}
viKeys := []string{"j", "k", "gg", "G", "<C-d>", "<C-u>", "<C-f>", "<C-b>", "<home>", "<end>"}
ui.On(viKeys, func(e ui.Event) {
switch e.Key {
case "j":
self.Down()
case "k":
self.Up()
case "<home>":
fallthrough
case "gg":
self.Top()
case "<end>":
fallthrough
case "G":
self.Bottom()
case "<C-d>":