mirror of
https://github.com/libretro/RetroArch
synced 2025-02-06 09:40:06 +00:00
(iOS/OSX) Build fixes
This commit is contained in:
parent
5af2d315c4
commit
9e26dec5fa
@ -138,9 +138,9 @@ void btpad_packet_handler(uint8_t packet_type,
|
||||
connection->channels[1] == channel))
|
||||
{
|
||||
pad_connection_packet(connection->slot, packet, size);
|
||||
apple->buttons[connection->slot] = pad_connection_get_buttons(connection->data);
|
||||
apple->buttons[connection->slot] = pad_connection_get_buttons(connection->slot);
|
||||
for (i = 0; i < 4; i++)
|
||||
apple->axes[device->slot][i] = pad_connection_get_axis(connection->data, i);
|
||||
apple->axes[connection->slot][i] = pad_connection_get_axis(connection->slot, i);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -153,9 +153,9 @@ static void hid_device_report(void* context, IOReturn result, void *sender,
|
||||
int i;
|
||||
|
||||
pad_connection_packet(connection->slot, connection->data, reportLength + 1);
|
||||
apple->buttons[connection->slot] = pad_connection_get_buttons(connection->data);
|
||||
apple->buttons[connection->slot] = pad_connection_get_buttons(connection->slot);
|
||||
for (i = 0; i < 4; i++)
|
||||
apple->axes[device->slot][i] = pad_connection_get_axis(connection->data, i);
|
||||
apple->axes[connection->slot][i] = pad_connection_get_axis(connection->slot, i);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -80,7 +80,6 @@ static uint32_t hidpad_wii_get_buttons(void *data)
|
||||
static void hidpad_wii_packet_handler(void *data,
|
||||
uint8_t *packet, uint16_t size)
|
||||
{
|
||||
int i;
|
||||
struct wiimote_t* device = (struct wiimote_t*)data;
|
||||
byte* msg = packet + 2;
|
||||
|
||||
|
@ -122,21 +122,21 @@ void pad_connection_packet(uint32_t pad,
|
||||
}
|
||||
}
|
||||
|
||||
uint32_t pad_connection_get_buttons(void *data, unsigned index)
|
||||
uint32_t pad_connection_get_buttons(unsigned index)
|
||||
{
|
||||
joypad_slot_t *s = (joypad_slot_t*)&slots[index];
|
||||
|
||||
if (s && s->iface && s->data)
|
||||
return s->iface->get_buttons(s->data, index);
|
||||
return s->iface->get_buttons(s->data);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int16_t pad_connection_get_axis(void *data, unsigned index, unsigned i)
|
||||
int16_t pad_connection_get_axis(unsigned index, unsigned i)
|
||||
{
|
||||
joypad_slot_t *s = (joypad_slot_t*)&slots[index];
|
||||
|
||||
if (s && s->iface && s->data)
|
||||
return s->iface->get_axis(s->data, index, i);
|
||||
return s->iface->get_axis(s->data, i);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -42,9 +42,9 @@ void pad_connection_disconnect(uint32_t slot);
|
||||
|
||||
void pad_connection_packet(uint32_t slot, uint8_t* data, uint32_t length);
|
||||
|
||||
uint32_t pad_connection_get_buttons(void *data);
|
||||
uint32_t pad_connection_get_buttons(unsigned index);
|
||||
|
||||
int16_t pad_connection_get_axis(void *data, unsigned i);
|
||||
int16_t pad_connection_get_axis(unsigned index, unsigned i);
|
||||
|
||||
/* Determine if connected joypad is a hidpad backed device.
|
||||
* If false, pad_connection_packet cannot be used */
|
||||
|
Loading…
x
Reference in New Issue
Block a user