mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-21 20:28:28 +00:00
Merged latest changes from Steam Link app
This commit is contained in:
parent
e2619f1dcf
commit
999af8099b
5 changed files with 72 additions and 3 deletions
|
@ -40,7 +40,7 @@
|
|||
|
||||
|
||||
/* Many controllers turn the center button into an instantaneous button press */
|
||||
#define SDL_MINIMUM_GUIDE_BUTTON_DELAY_MS 100
|
||||
#define SDL_MINIMUM_GUIDE_BUTTON_DELAY_MS 250
|
||||
|
||||
#define SDL_CONTROLLER_PLATFORM_FIELD "platform:"
|
||||
|
||||
|
@ -929,6 +929,7 @@ static ControllerMapping_t *SDL_CreateMappingForAndroidController(const char *na
|
|||
if (button_mask & (1 << SDL_CONTROLLER_BUTTON_BACK)) {
|
||||
SDL_strlcat(mapping_string, "back:b4,", sizeof(mapping_string));
|
||||
}
|
||||
#if 0 /* The guide button generally isn't functional (or acts as a home button) on most Android controllers */
|
||||
if (button_mask & (1 << SDL_CONTROLLER_BUTTON_GUIDE)) {
|
||||
SDL_strlcat(mapping_string, "guide:b5,", sizeof(mapping_string));
|
||||
#if 0 /* Actually this will be done in Steam */
|
||||
|
@ -940,6 +941,7 @@ static ControllerMapping_t *SDL_CreateMappingForAndroidController(const char *na
|
|||
button_mask &= ~(1 << SDL_CONTROLLER_BUTTON_START);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
if (button_mask & (1 << SDL_CONTROLLER_BUTTON_START)) {
|
||||
SDL_strlcat(mapping_string, "start:b6,", sizeof(mapping_string));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue