mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-11 22:42:31 +02:00
Updated source to match SDL function prototype style
This commit is contained in:
@@ -1736,8 +1736,7 @@ static GCControllerDirectionPad *GetDirectionalPadForController(GCController *co
|
||||
|
||||
static char elementName[256];
|
||||
|
||||
const char *
|
||||
IOS_GetAppleSFSymbolsNameForButton(SDL_Gamepad *gamepad, SDL_GamepadButton button)
|
||||
const char *IOS_GetAppleSFSymbolsNameForButton(SDL_Gamepad *gamepad, SDL_GamepadButton button)
|
||||
{
|
||||
elementName[0] = '\0';
|
||||
#if defined(SDL_JOYSTICK_MFI) && defined(ENABLE_PHYSICAL_INPUT_PROFILE)
|
||||
@@ -1852,8 +1851,7 @@ IOS_GetAppleSFSymbolsNameForButton(SDL_Gamepad *gamepad, SDL_GamepadButton butto
|
||||
return elementName;
|
||||
}
|
||||
|
||||
const char *
|
||||
IOS_GetAppleSFSymbolsNameForAxis(SDL_Gamepad *gamepad, SDL_GamepadAxis axis)
|
||||
const char *IOS_GetAppleSFSymbolsNameForAxis(SDL_Gamepad *gamepad, SDL_GamepadAxis axis)
|
||||
{
|
||||
elementName[0] = '\0';
|
||||
#if defined(SDL_JOYSTICK_MFI) && defined(ENABLE_PHYSICAL_INPUT_PROFILE)
|
||||
|
||||
@@ -699,15 +699,13 @@ static void DARWIN_JoystickDetect(void)
|
||||
}
|
||||
}
|
||||
|
||||
const char *
|
||||
DARWIN_JoystickGetDeviceName(int device_index)
|
||||
const char *DARWIN_JoystickGetDeviceName(int device_index)
|
||||
{
|
||||
recDevice *device = GetDeviceForIndex(device_index);
|
||||
return device ? device->product : "UNKNOWN";
|
||||
}
|
||||
|
||||
const char *
|
||||
DARWIN_JoystickGetDevicePath(int device_index)
|
||||
const char *DARWIN_JoystickGetDevicePath(int device_index)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -1783,8 +1783,7 @@ static void HandleSimpleControllerState(SDL_Joystick *joystick, SDL_DriverSwitch
|
||||
ctx->m_lastSimpleState = *packet;
|
||||
}
|
||||
|
||||
static void
|
||||
SendSensorUpdate(Uint64 timestamp, SDL_Joystick *joystick, SDL_DriverSwitch_Context *ctx, SDL_SensorType type, Uint64 sensor_timestamp, const Sint16 *values)
|
||||
static void SendSensorUpdate(Uint64 timestamp, SDL_Joystick *joystick, SDL_DriverSwitch_Context *ctx, SDL_SensorType type, Uint64 sensor_timestamp, const Sint16 *values)
|
||||
{
|
||||
float data[3];
|
||||
|
||||
|
||||
@@ -1240,8 +1240,7 @@ SDL_bool HIDAPI_IsDevicePresent(Uint16 vendor_id, Uint16 product_id, Uint16 vers
|
||||
return result;
|
||||
}
|
||||
|
||||
SDL_JoystickType
|
||||
HIDAPI_GetJoystickTypeFromGUID(SDL_JoystickGUID guid)
|
||||
SDL_JoystickType HIDAPI_GetJoystickTypeFromGUID(SDL_JoystickGUID guid)
|
||||
{
|
||||
SDL_HIDAPI_Device *device;
|
||||
SDL_JoystickType type = SDL_JOYSTICK_TYPE_UNKNOWN;
|
||||
@@ -1258,8 +1257,7 @@ HIDAPI_GetJoystickTypeFromGUID(SDL_JoystickGUID guid)
|
||||
return type;
|
||||
}
|
||||
|
||||
SDL_GamepadType
|
||||
HIDAPI_GetGamepadTypeFromGUID(SDL_JoystickGUID guid)
|
||||
SDL_GamepadType HIDAPI_GetGamepadTypeFromGUID(SDL_JoystickGUID guid)
|
||||
{
|
||||
SDL_HIDAPI_Device *device;
|
||||
SDL_GamepadType type = SDL_GAMEPAD_TYPE_UNKNOWN;
|
||||
|
||||
@@ -591,8 +591,7 @@ err:
|
||||
#undef CHECK
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
SDL_DINPUT_JoystickPresent(Uint16 vendor_id, Uint16 product_id, Uint16 version_number)
|
||||
SDL_bool SDL_DINPUT_JoystickPresent(Uint16 vendor_id, Uint16 product_id, Uint16 version_number)
|
||||
{
|
||||
Joystick_PresentData data;
|
||||
|
||||
@@ -1176,8 +1175,7 @@ void SDL_DINPUT_JoystickDetect(JoyStick_DeviceData **pContext)
|
||||
{
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
SDL_DINPUT_JoystickPresent(Uint16 vendor, Uint16 product, Uint16 version)
|
||||
SDL_bool SDL_DINPUT_JoystickPresent(Uint16 vendor, Uint16 product, Uint16 version)
|
||||
{
|
||||
return SDL_FALSE;
|
||||
}
|
||||
|
||||
@@ -878,14 +878,12 @@ static int RAWINPUT_JoystickGetCount(void)
|
||||
return SDL_RAWINPUT_numjoysticks;
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
RAWINPUT_IsEnabled()
|
||||
SDL_bool RAWINPUT_IsEnabled()
|
||||
{
|
||||
return SDL_RAWINPUT_inited;
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
RAWINPUT_IsDevicePresent(Uint16 vendor_id, Uint16 product_id, Uint16 version, const char *name)
|
||||
SDL_bool RAWINPUT_IsDevicePresent(Uint16 vendor_id, Uint16 product_id, Uint16 version, const char *name)
|
||||
{
|
||||
SDL_RAWINPUT_Device *device;
|
||||
|
||||
@@ -1886,8 +1884,7 @@ static void RAWINPUT_JoystickClose(SDL_Joystick *joystick)
|
||||
}
|
||||
}
|
||||
|
||||
SDL_bool
|
||||
RAWINPUT_RegisterNotifications(HWND hWnd)
|
||||
SDL_bool RAWINPUT_RegisterNotifications(HWND hWnd)
|
||||
{
|
||||
RAWINPUTDEVICE rid[SDL_arraysize(subscribed_devices)];
|
||||
int i;
|
||||
|
||||
Reference in New Issue
Block a user