This change adds these APIs to inpututil:
* IsStandardGamepadButtonJustPressed
* IsStandardGamepadButtonJustReleased
* StandardGamepadButtonPressDuration
Closes#1557
This change introduces the standard gamepad layout. This changes adds
these APIs:
* func HasGamepadStandardLayoutMapping
* func IsGamepadStandardButtonPressed
* func GamepadStandardAxisValue
* type StandardGamepadButton
* type StandardGamepadAxis
The standard gamepad layout is based on the web standard. See
https://www.w3.org/TR/gamepad/#remapping.
On desktops, the SDL's gamecontrllerdb.txt is used. If the gamepad is
listed in the text file, the mapping works. GLFW's mapping featrue is
not used.
On browsers, the property of a gamepad 'mapping' is used. When the
mapping value is 'standard', the gamepad is recognized to have the
standard mapping.
On mobiles, the implementation is still WIP.
Updates #1557
Using restorable images is expensive as this sometimes requires to
load pixels from GPU. On browsers, just reloading the application
should be fine when the context lost happens.
Closes#1603
IsWindowBeingClosed reports whether the window is being closed by
the user.
SetWindowClosingHandled sets whether the window closing is handled
or not. If the state is true, the window is not closed immediately
by the user and the game can handle the closing state. In this case,
the Update function should return an error in order to end the game.
This change also adds examples/windowclosing.
Closes#1574
On Windows, cursor colors are determined based on the background
color, and if the background color is gray, the cursor might be
invisible. This change adjust the color so that the cursor should
be visible in any cases.
Closes#1583
This change adds APIs to enable to use system cursor shapes other
than the default shape (an arrow).
This change doesn't add these cursors since they seem a little
different on macOS from the other platforms.
* GLFW_HRESIZE_CURSOR
* GLFW_VRESIZE_CURSOR
Closes#995