add ARCHOS gamepad

This commit is contained in:
radius 2015-12-09 10:00:32 -05:00
parent e28450368f
commit 08f42beefb

View File

@ -647,25 +647,25 @@ static void handle_hotplug(android_input_data_t *android_data,
} }
/* GPD XD */ /* GPD XD */
else if(strstr(device_model, "XD") && ( else if(strstr(device_model, "XD") && (
strstr(device_name, "Virtual") || strstr(device_name, "rk29-keypad") || strstr(device_name, "Virtual") || strstr(device_name, "rk29-keypad") ||
strstr(device_name,"Playstation3") || strstr(device_name,"XBOX"))) strstr(device_name,"Playstation3") || strstr(device_name,"XBOX")))
{ {
/* only use the hack if the device is one of the built-in devices */ /* only use the hack if the device is one of the built-in devices */
RARCH_LOG("GPD XD Detected: %s\n", device_model); RARCH_LOG("GPD XD Detected: %s\n", device_model);
{ {
if ( primary_id < 0 ) if ( primary_id < 0 )
primary_id = id; primary_id = id;
else else
secondary_id = id; secondary_id = id;
if ( secondary_id > 0) if ( secondary_id > 0)
return; return;
strlcpy (name_buf, "GPD XD", sizeof(name_buf)); strlcpy (name_buf, "GPD XD", sizeof(name_buf));
*port = 0; *port = 0;
} }
} }
/* XPERIA Play */ /* XPERIA Play */
else if(strstr(device_model, "R800") && ( else if(strstr(device_model, "R800") && (
@ -687,6 +687,26 @@ static void handle_hotplug(android_input_data_t *android_data,
} }
} }
/* ARCHOS Gamepad */
else if(strstr(device_model, "ARCHOS GAMEPAD") && (
strstr(device_name, "joy_key") || strstr(device_name, "joystick")))
{
/* only use the hack if the device is one of the built-in devices */
RARCH_LOG("ARCHOS GAMEPAD Detected: %s\n", device_model);
{
if ( primary_id < 0 )
primary_id = id;
else
secondary_id = id;
if ( secondary_id > 0)
return;
strlcpy (name_buf, "ARCHOS GamePad", sizeof(name_buf));
*port = 0;
}
}
else if (strstr(device_name, "iControlPad-")) else if (strstr(device_name, "iControlPad-"))
strlcpy(name_buf, "iControlPad HID Joystick profile", sizeof(name_buf)); strlcpy(name_buf, "iControlPad HID Joystick profile", sizeof(name_buf));