mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-12 22:17:26 +01:00
uidriver/mobile: Remove time-out logic
This was introduced at 8121b2102f
.
I am not sure the reason.
As Render must sync with updating and never returns until updating
finishes, the time-out case should never be chosen.
This commit is contained in:
parent
13ce1c28b4
commit
2dc6042858
@ -64,17 +64,11 @@ func (u *UserInterface) Render(chError <-chan error) error {
|
|||||||
}
|
}
|
||||||
// TODO: Check this is called on the rendering thread
|
// TODO: Check this is called on the rendering thread
|
||||||
|
|
||||||
t := time.NewTimer(500 * time.Millisecond)
|
|
||||||
defer t.Stop()
|
|
||||||
|
|
||||||
select {
|
select {
|
||||||
case err := <-chError:
|
case err := <-chError:
|
||||||
return err
|
return err
|
||||||
case renderCh <- struct{}{}:
|
case renderCh <- struct{}{}:
|
||||||
return opengl.Get().DoWork(renderEndCh)
|
return opengl.Get().DoWork(renderEndCh)
|
||||||
case <-t.C:
|
|
||||||
// This function must not be blocked. We need to break for timeout.
|
|
||||||
return nil
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user