Update GLFW: suppress joystick issue

Updates #1229
This commit is contained in:
Hajime Hoshi 2021-07-14 23:52:27 +09:00
parent 9e024dc337
commit 66dbca7fdd
3 changed files with 8 additions and 4 deletions

2
go.mod
View File

@ -3,7 +3,7 @@ module github.com/hajimehoshi/ebiten/v2
go 1.15 go 1.15
require ( require (
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210410170116-ea3d685f79fb github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210714145042-ef648d7b4198
github.com/gofrs/flock v0.8.0 github.com/gofrs/flock v0.8.0
github.com/hajimehoshi/bitmapfont/v2 v2.1.3 github.com/hajimehoshi/bitmapfont/v2 v2.1.3
github.com/hajimehoshi/file2byteslice v0.0.0-20200812174855-0e5e8a80490e github.com/hajimehoshi/file2byteslice v0.0.0-20200812174855-0e5e8a80490e

4
go.sum
View File

@ -1,6 +1,6 @@
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210410170116-ea3d685f79fb h1:T6gaWBvRzJjuOrdCtg8fXXjKai2xSDqWTcKFUPuw8Tw= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210714145042-ef648d7b4198 h1:ucTpB2JPNdBbIedBwFGl3p8j94ecAIYfkoYV7r3nV+E=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210410170116-ea3d685f79fb/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210714145042-ef648d7b4198/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
github.com/gofrs/flock v0.8.0 h1:MSdYClljsF3PbENUUEx85nkWfJSGfzYI9yEBZOJz6CY= github.com/gofrs/flock v0.8.0 h1:MSdYClljsF3PbENUUEx85nkWfJSGfzYI9yEBZOJz6CY=
github.com/gofrs/flock v0.8.0/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/flock v0.8.0/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU=
github.com/hajimehoshi/bitmapfont/v2 v2.1.3 h1:JefUkL0M4nrdVwVq7MMZxSTh6mSxOylm+C4Anoucbb0= github.com/hajimehoshi/bitmapfont/v2 v2.1.3 h1:JefUkL0M4nrdVwVq7MMZxSTh6mSxOylm+C4Anoucbb0=

View File

@ -419,7 +419,11 @@ func GetPrimaryMonitor() *Monitor {
func Init() error { func Init() error {
glfwDLL.call("glfwInit") glfwDLL.call("glfwInit")
return acceptError(APIUnavailable) // InvalidValue can happen when specific joysticks are used. This issue
// will be fixed in GLFW 3.3.5. As a temporary fix, accept this error.
// See go-gl/glfw#292, go-gl/glfw#324, and glfw/glfw#1763
// (#1229).
return acceptError(APIUnavailable, InvalidValue)
} }
func (j Joystick) Present() bool { func (j Joystick) Present() bool {