fix: prevent double repaint when restoring terminal

This commit is contained in:
Christian Muehlhaeuser 2022-10-09 05:41:12 +02:00
parent 1c3b792596
commit e119cd88b2
1 changed files with 3 additions and 2 deletions

5
tea.go
View File

@ -572,10 +572,11 @@ func (p *Program) RestoreTerminal() error {
if p.altScreenWasActive {
p.renderer.enterAltScreen()
} else {
// entering alt screen already causes a repaint.
go p.Send(repaintMsg{})
}
go p.Send(repaintMsg{})
return nil
}