Fixed mouse cursor bug.

If the Run loop was non-blocking (wait set to false) the cursor was reset back to the default.
This commit is contained in:
Sander Schobers 2019-07-04 22:03:29 +02:00
parent a6bb05794f
commit 3bd4001cc3

View File

@ -54,7 +54,10 @@ func (r *Renderer) PushEvents(t ui.EventTarget, wait bool) {
r.newCursor = ui.MouseCursorDefault
var ev = eventWait(r.eq, wait)
for nil != ev {
if ev == nil {
return
}
for ev != nil {
switch e := ev.(type) {
case *allg5.DisplayCloseEvent:
t.Handle(&ui.DisplayCloseEvent{EventBase: eventBase(e)})