2
0
mirror of https://github.com/junegunn/fzf synced 2024-11-18 09:28:40 +00:00

Avoid superfluous update of scrollbar

This commit is contained in:
Junegunn Choi 2023-01-02 01:10:01 +09:00
parent aa71a07fbe
commit 3761dc0433
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

View File

@ -1423,6 +1423,7 @@ func (t *Terminal) printItem(result Result, line int, i int, current bool, bar b
prevLine := t.prevLines[i]
printBar := func() {
if len(t.scrollbar) > 0 && bar != prevLine.bar {
t.prevLines[i].bar = bar
t.move(line, t.window.Width()-1, true)
if bar {
t.window.CPrint(tui.ColScrollbar, t.scrollbar)