ui: Need LockOSThread for mobile

This commit is contained in:
Hajime Hoshi 2016-07-01 00:44:15 +09:00
parent c50f5a3509
commit 47a0b3ccfa

View File

@ -18,6 +18,7 @@ package ui
import (
"errors"
"runtime"
"time"
"github.com/hajimehoshi/ebiten/internal/graphics/opengl"
@ -32,6 +33,9 @@ func Main() error {
}
func Render(chError <-chan error) error {
runtime.LockOSThread()
defer runtime.UnlockOSThread()
if chError == nil {
return errors.New("ui: chError must not be nil")
}