Add toggle-track action

This commit is contained in:
Junegunn Choi
2023-04-22 15:48:51 +09:00
parent 7c6f5dba63
commit 0c61d81713
3 changed files with 48 additions and 1 deletions

View File

@@ -337,6 +337,7 @@ const (
actToggleUp
actToggleIn
actToggleOut
actToggleTrack
actDown
actUp
actPageUp
@@ -1464,6 +1465,9 @@ func (t *Terminal) printInfo() {
output += " -S"
}
}
if t.track {
output += " +T"
}
if t.multi > 0 {
if t.multi == maxMulti {
output += fmt.Sprintf(" (%d)", len(t.selected))
@@ -3274,6 +3278,9 @@ func (t *Terminal) Loop() {
t.paused = !t.paused
changed = !t.paused
req(reqPrompt)
case actToggleTrack:
t.track = !t.track
req(reqInfo)
case actEnableSearch:
t.paused = false
changed = true