mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
ui: Refactoring
This commit is contained in:
parent
443e3ae3a4
commit
7e29a81177
@ -229,9 +229,8 @@ func (u *userInterface) update(g GraphicsContext) error {
|
||||
|
||||
func (u *userInterface) loop(g GraphicsContext) error {
|
||||
ch := make(chan error)
|
||||
var f func([]js.Value)
|
||||
var cf js.Callback
|
||||
f = func([]js.Value) {
|
||||
f := func([]js.Value) {
|
||||
if err := u.update(g); err != nil {
|
||||
ch <- err
|
||||
close(ch)
|
||||
|
Loading…
Reference in New Issue
Block a user