forked from Mirrors/bubbletea
Fix render's view clearing loop
This commit is contained in:
parent
217c506a49
commit
830beecffb
|
@ -148,13 +148,14 @@ func (r *renderer) flush() {
|
|||
if r.linesRendered > 0 {
|
||||
// Clear the lines we painted in the last render.
|
||||
for i := r.linesRendered; i > 0; i-- {
|
||||
cursorUp(out)
|
||||
|
||||
// Check and see if we should skip rendering for this line. That
|
||||
// includes clearing the line, which we normally do before a
|
||||
// render.
|
||||
if _, exists := r.ignoreLines[i]; !exists {
|
||||
clearLine(out)
|
||||
}
|
||||
cursorUp(out)
|
||||
}
|
||||
}
|
||||
r.linesRendered = 0
|
||||
|
|
Loading…
Reference in New Issue