From 1a01dc6ba10c85d5b1c693bd6e3c460f79b93669 Mon Sep 17 00:00:00 2001 From: Travis Howse Date: Sun, 14 Aug 2022 23:16:21 +1000 Subject: [PATCH] Actual fix. --- application.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application.go b/application.go index 5433c00..09ad24a 100644 --- a/application.go +++ b/application.go @@ -181,6 +181,7 @@ func (a *Application) SetScreen(screen tcell.Screen) *Application { // Run() has not been called yet. a.screen = screen a.Unlock() + screen.Init() return a } @@ -284,9 +285,8 @@ func (a *Application) Run() error { a.screen = screen enableMouse := a.enableMouse a.Unlock() - // Initialize and draw this screen. - if err := a.screen.Init(); err != nil { + if err := screen.Init(); err != nil { panic(err) } if enableMouse {