mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-09 08:00:55 +00:00
Merge commit '85924687fd' into main
This commit is contained in:
commit
21b121b6df
2 changed files with 2 additions and 2 deletions
|
|
@ -223,7 +223,7 @@ extern DECLSPEC int SDLCALL SDL_GetSensorNonPortableType(SDL_Sensor *sensor);
|
|||
* Get the instance ID of a sensor.
|
||||
*
|
||||
* \param sensor The SDL_Sensor object to inspect
|
||||
* \returns the sensor instance ID, or -1 if `sensor` is NULL.
|
||||
* \returns the sensor instance ID, or 0 if `sensor` is NULL.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -374,7 +374,7 @@ int SDL_GetSensorNonPortableType(SDL_Sensor *sensor)
|
|||
SDL_SensorID SDL_GetSensorInstanceID(SDL_Sensor *sensor)
|
||||
{
|
||||
if (!SDL_IsSensorValid(sensor)) {
|
||||
return -1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
return sensor->instance_id;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue