mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
Change returntype of pad_connection_init
This commit is contained in:
parent
8cf59bbffc
commit
123b85dbb0
@ -35,7 +35,7 @@ int pad_connection_find_vacant_pad(joypad_connection_t *joyconn)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
void *pad_connection_init(unsigned pads)
|
joypad_connection_t *pad_connection_init(unsigned pads)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
joypad_connection_t *joyconn = (joypad_connection_t*)
|
joypad_connection_t *joyconn = (joypad_connection_t*)
|
||||||
|
@ -49,7 +49,7 @@ int32_t pad_connection_pad_init(joypad_connection_t *joyconn,
|
|||||||
const char* name, uint16_t vid, uint16_t pid,
|
const char* name, uint16_t vid, uint16_t pid,
|
||||||
void *data, send_control_t ptr);
|
void *data, send_control_t ptr);
|
||||||
|
|
||||||
void *pad_connection_init(unsigned pads);
|
joypad_connection_t *pad_connection_init(unsigned pads);
|
||||||
|
|
||||||
void pad_connection_destroy(joypad_connection_t *joyconn);
|
void pad_connection_destroy(joypad_connection_t *joyconn);
|
||||||
|
|
||||||
|
@ -833,7 +833,10 @@ static void *btstack_hid_init(void)
|
|||||||
if (!hid)
|
if (!hid)
|
||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
hid->slots = (joypad_connection_t*)pad_connection_init(MAX_USERS);
|
hid->slots = pad_connection_init(MAX_USERS);
|
||||||
|
|
||||||
|
if (!hid->slots)
|
||||||
|
goto error;
|
||||||
|
|
||||||
return hid;
|
return hid;
|
||||||
|
|
||||||
|
@ -425,8 +425,10 @@ static void *iohidmanager_hid_init(void)
|
|||||||
if (iohidmanager_hid_manager_set_device_matching(hid_apple) == -1)
|
if (iohidmanager_hid_manager_set_device_matching(hid_apple) == -1)
|
||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
hid_apple->slots = (joypad_connection_t*)pad_connection_init(MAX_USERS);
|
hid_apple->slots = pad_connection_init(MAX_USERS);
|
||||||
|
|
||||||
|
if (!hid_apple->slots)
|
||||||
|
goto error;
|
||||||
|
|
||||||
return hid_apple;
|
return hid_apple;
|
||||||
|
|
||||||
|
@ -498,7 +498,10 @@ static void *libusb_hid_init(void)
|
|||||||
if (!libusb_has_capability(LIBUSB_CAP_HAS_HOTPLUG))
|
if (!libusb_has_capability(LIBUSB_CAP_HAS_HOTPLUG))
|
||||||
goto error;
|
goto error;
|
||||||
|
|
||||||
hid->slots = (joypad_connection_t*)pad_connection_init(MAX_USERS);
|
hid->slots = pad_connection_init(MAX_USERS);
|
||||||
|
|
||||||
|
if (!hid->slots)
|
||||||
|
goto error;
|
||||||
|
|
||||||
count = libusb_get_device_list(NULL, &devices);
|
count = libusb_get_device_list(NULL, &devices);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user