Skip to content

Commit

Permalink
trigger searches after mods
Browse files Browse the repository at this point in the history
  • Loading branch information
boyter committed Jul 13, 2020
1 parent b3644f2 commit f58d254
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions processor/tui2.go
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,10 @@ func NewTuiApplication() {
}
}
LocationExcludePattern = t

snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
applicationController.ResetOffset()
applicationController.SetQuery(strings.TrimSpace(inputField.GetText()))
}).
SetDoneFunc(func(key tcell.Key) {
switch key {
Expand Down Expand Up @@ -486,15 +490,26 @@ func NewTuiApplication() {
case tcell.KeyUp:
SnippetLength = min(SnippetLength+50, 8000)
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
applicationController.ResetOffset()
applicationController.SetQuery(strings.TrimSpace(inputField.GetText()))
case tcell.KeyPgUp:
SnippetLength = min(SnippetLength+200, 8000)
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
applicationController.ResetOffset()
applicationController.SetQuery(strings.TrimSpace(inputField.GetText()))
case tcell.KeyDown:
SnippetLength = max(50, SnippetLength-50)
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
applicationController.ResetOffset()
applicationController.SetQuery(strings.TrimSpace(inputField.GetText()))
case tcell.KeyPgDn:
SnippetLength = max(50, SnippetLength-200)
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
snippetInputField.SetText(strconv.Itoa(int(SnippetLength)))
applicationController.ResetOffset()
applicationController.SetQuery(strings.TrimSpace(inputField.GetText()))
}
})

Expand Down

0 comments on commit f58d254

Please sign in to comment.