diff --git a/CHANGELOG b/CHANGELOG index c3eb7ba..142a39b 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,6 +1,7 @@ v1.5.7 (WIP) - Add Application.HandlePanic - Add Modal.SetButtonsAlign and Modal.SetTextAlign +- Fix Application.QueueEvent - Fix TextView.GetRegionText error when text contains color tags - Fix TextView region tags when placed at the end of a line - Do not customize Modal window styling by default (use GetForm and GetFrame to customize) diff --git a/application.go b/application.go index dacba78..4266b94 100644 --- a/application.go +++ b/application.go @@ -451,6 +451,16 @@ func (a *Application) Run() error { } }() + go func() { + defer a.HandlePanic() + + for event := range a.events { + semaphore.Lock() + handle(event) + semaphore.Unlock() + } + }() + // Start screen event loop. for { a.Lock()