We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5223 - Xbox One Controller Menu button not registering as Start on Android
Summary: Xbox One Controller Menu button not registering as Start on Android
Status: NEW
Alias: None
Product: SDL
Classification: Unclassified
Component: joystick (show other bugs)
Version: 2.0.12
Hardware: All Android (All)
: P2 normal
Assignee: Sam Lantinga
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-06 15:27 UTC by sdlbugs
Modified: 2020-07-06 15:27 UTC (History)
0 users

See Also:


Attachments
Patch which allows Android to read Xbox One Menu Button as Start (505 bytes, patch)
2020-07-06 15:27 UTC, sdlbugs
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description sdlbugs 2020-07-06 15:27:03 UTC
Created attachment 4404 [details]
Patch which allows Android to read Xbox One Menu Button as Start

Just spotted this during testing. 

Xbox One Wireless Controller (Model 1708) connected via Bluetooth to Amazon Fire TV (AFTT).

The Menu Button (as per diagram here: https://support.xbox.com/help/hardware-network/controller/xbox-one-wireless-controller) reports on most platforms as SDL_CONTROLLER_BUTTON_START but on Android is completely ignored.

It's an easy fix of adding a case for AKEYCODE_MENU to the switch in keycode_to_SDL() in SDL_sysjoystick.c to map the button to SDL_CONTROLLER_BUTTON_START:

        case AKEYCODE_BUTTON_START:
        case AKEYCODE_MENU:    // <-- New bit
            button = SDL_CONTROLLER_BUTTON_START;
            break;

Patch attached.