mirror of https://github.com/liamg/aminal.git
Fix page up/down and application home/insert
This commit is contained in:
parent
ae5ba2ab37
commit
f07ca0cca3
52
gui/input.go
52
gui/input.go
|
@ -127,33 +127,33 @@ func (gui *GUI) key(w *glfw.Window, key glfw.Key, scancode int, action glfw.Acti
|
||||||
'3', '~',
|
'3', '~',
|
||||||
})
|
})
|
||||||
case glfw.KeyHome:
|
case glfw.KeyHome:
|
||||||
if gui.terminal.IsApplicationCursorKeysModeEnabled() {
|
gui.terminal.Write([]byte{
|
||||||
gui.terminal.Write([]byte{
|
0x1b,
|
||||||
0x1b,
|
'[',
|
||||||
'O',
|
'1',
|
||||||
'H',
|
'~',
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
gui.terminal.Write([]byte{
|
|
||||||
0x1b,
|
|
||||||
'[',
|
|
||||||
'H',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
case glfw.KeyEnd:
|
case glfw.KeyEnd:
|
||||||
if gui.terminal.IsApplicationCursorKeysModeEnabled() {
|
gui.terminal.Write([]byte{
|
||||||
gui.terminal.Write([]byte{
|
0x1b,
|
||||||
0x1b,
|
'[',
|
||||||
'O',
|
'4',
|
||||||
'F',
|
'~',
|
||||||
})
|
})
|
||||||
} else {
|
case glfw.KeyPageUp:
|
||||||
gui.terminal.Write([]byte{
|
gui.terminal.Write([]byte{
|
||||||
0x1b,
|
0x1b,
|
||||||
'[',
|
'[',
|
||||||
'F',
|
'5',
|
||||||
})
|
'~',
|
||||||
}
|
})
|
||||||
|
case glfw.KeyPageDown:
|
||||||
|
gui.terminal.Write([]byte{
|
||||||
|
0x1b,
|
||||||
|
'[',
|
||||||
|
'6',
|
||||||
|
'~',
|
||||||
|
})
|
||||||
case glfw.KeyEscape:
|
case glfw.KeyEscape:
|
||||||
if gui.terminal.IsApplicationCursorKeysModeEnabled() {
|
if gui.terminal.IsApplicationCursorKeysModeEnabled() {
|
||||||
gui.terminal.Write([]byte{
|
gui.terminal.Write([]byte{
|
||||||
|
|
Loading…
Reference in New Issue