mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 10:48:53 +01:00
internal/ui: handle gamepad errors
This commit is contained in:
parent
0cd43bd081
commit
f1037d8bff
@ -203,6 +203,8 @@ func (i *Input) update(window *glfw.Window, context *context) error {
|
||||
i.cursorX, i.cursorY = int(cx), int(cy)
|
||||
}
|
||||
|
||||
gamepad.Update()
|
||||
if err := gamepad.Update(); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
@ -290,7 +290,9 @@ func (u *userInterfaceImpl) updateImpl(force bool) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
gamepad.Update()
|
||||
if err := gamepad.Update(); err != nil {
|
||||
return err
|
||||
}
|
||||
u.input.updateForGo2Cpp()
|
||||
|
||||
a := u.DeviceScaleFactor()
|
||||
|
@ -79,7 +79,9 @@ func (u *userInterfaceImpl) Update() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
gamepad.Update()
|
||||
if err := gamepad.Update(); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
renderCh <- struct{}{}
|
||||
go func() {
|
||||
|
Loading…
Reference in New Issue
Block a user