Check bounds in SDL_IsGameController. Switch two functions to SDL_bool.
Switches SDL_GameControllerGetAttached and SDL_IsGameController to return SDL_bool, instead of int.
This commit is contained in:
parent
3e60f92228
commit
e34e953eba
2 changed files with 13 additions and 7 deletions
|
@ -113,7 +113,7 @@ typedef struct _SDL_GameControllerButtonBind
|
|||
* Is the joystick on this index supported by the game controller interface?
|
||||
* returns 1 if supported, 0 otherwise.
|
||||
*/
|
||||
extern DECLSPEC int SDLCALL SDL_IsGameController(int joystick_index);
|
||||
extern DECLSPEC SDL_bool SDLCALL SDL_IsGameController(int joystick_index);
|
||||
|
||||
|
||||
/**
|
||||
|
@ -141,7 +141,7 @@ extern DECLSPEC const char *SDLCALL SDL_GameControllerName(SDL_GameController *
|
|||
/**
|
||||
* Returns 1 if the controller has been opened and currently connected, or 0 if it has not.
|
||||
*/
|
||||
extern DECLSPEC int SDLCALL SDL_GameControllerGetAttached(SDL_GameController * gamecontroller);
|
||||
extern DECLSPEC SDL_bool SDLCALL SDL_GameControllerGetAttached(SDL_GameController * gamecontroller);
|
||||
|
||||
/**
|
||||
* Get the underlying joystick object used by a controller
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue