mirror of
https://github.com/jesseduffield/lazydocker.git
synced 2026-07-25 08:31:03 +00:00
fix: blank screen after exiting exec shell
after exec-ing into a container and ctrl+d-ing out, the screen goes completely blank. you have to kill and relaunch lazydocker to get it back. been happening on kitty, warp, and wsl. the issue is in gocui's Resume() — tcell re-engages the terminal but its cell cache still thinks the old content is on screen. next redraw diffs against stale cache, sees "nothing changed", writes nothing. blank screen. adding screen.Sync() after Resume() nukes the cache and forces a full repaint. tested on kitty + orbstack, redraws clean every time. fixes #611
This commit is contained in:
parent
2ebe3848d6
commit
858ff1806e
1 changed files with 12 additions and 1 deletions
13
vendor/github.com/jesseduffield/gocui/gui.go
generated
vendored
13
vendor/github.com/jesseduffield/gocui/gui.go
generated
vendored
|
|
@ -1546,7 +1546,18 @@ func (g *Gui) Resume() error {
|
|||
|
||||
g.suspended = false
|
||||
|
||||
return g.screen.Resume()
|
||||
if err := g.screen.Resume(); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Resume() re-engages the terminal but leaves tcell's internal
|
||||
// "last drawn" cell cache stale. Without Sync(), the next redraw
|
||||
// diffs against that stale cache, finds nothing changed, and
|
||||
// writes nothing — leaving the screen blank. Sync() invalidates
|
||||
// the cache so the next Show() forces a full repaint.
|
||||
g.screen.Sync()
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// matchView returns if the keybinding matches the current view (and the view's context)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue