Replies: 1 comment
-
Use // Automatically refresh the GUI main window every 500 millisecond using a ticker.
refreshTicker := time.NewTicker(500 * time.Millisecond)
refreshTickerDone := make(chan bool)
...
go func() {
for {
select {
case <-refreshTickerDone:
return
case <-refreshTicker.C:
imgui.Refresh()
}
}
}()
...
// Stop refresh ticker.
refreshTicker.Stop()
refreshTickerDone <- true |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
How to force window redraw, e.g. from another goroutine?
Beta Was this translation helpful? Give feedback.
All reactions