The gamepad poll keeps its buttons by position, the Home button and the trigger axes, and input_pad_combo reads a combo setting

pad_read stores what pad_physical saw (pad_seen, by PAD_* position, with the Home / Guide button after the Switch
buttons as PAD_GUIDE) and the two trigger axes (trigger_seen), under the input lock, for gamepad combos that are no
Switch buttons and for analog trigger readers. input_pad_combo parses a setting of button positions joined with +
(the bind_ lines' pad: names plus guide or home) into a mask, logging a name that is no button. input_map.c exports
input_key_id and input_pad_id, and ui/binds_page.cpp binds_pad_label gives the label the open pad has on a button,
so menu rows can name buttons as the Controls tab does. No behaviour changes on its own.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
lebomisandClaude Opus 5.5 committed 2026-11-19 13:32:22 +11:00
1 parent ebce67b367
commit 94c33b1d85
6 files changed
+54 -5

No files matched your search

+2
View File
@@ -122,6 +122,8 @@ static const char *pad_label(int p) {
return menu_text((UiTextId)(UI_PAD_SOUTH + (p - PAD_SOUTH)));
}
const char *binds_pad_label(int pad) { return pad_label(pad); }
// The layout the gamepad cells show: the one in effect, or without a gamepad the one the setting names (Xbox for auto).
static int shown_layout(void) {
int l = input_pad_layout();