mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Add confirmation and removal to bindings menu
This makes the following improvements to the gamepad bindings menu:
- The menu now shows a hint that you can press a button while any of
the bind options are selected (or that you can navigate away from
those options)
- Instead of button presses immediately setting a binding, they now
ask for confirmation: press the same button a second time to confirm
- You can now remove a binding, the same way you add it (this has the
same type of confirmation)
- This menu used to be inconsistent with pretty much every other menu
in the game by showing a permanent title and description for the menu
itself ("Game Pad", "Change controller options.") rather than showing
a title and description for the currently selected option.
This inconsistency is now fixed.
This commit is contained in:
@@ -272,7 +272,7 @@ const char* BUTTONGLYPHS_get_wasd_text(void)
|
||||
return loc::gettext("Press left/right to move");
|
||||
}
|
||||
|
||||
static const char* sdlbutton_to_glyph(const SDL_GameControllerButton button)
|
||||
const char* BUTTONGLYPHS_sdlbutton_to_glyph(const SDL_GameControllerButton button)
|
||||
{
|
||||
if (button > SDL_CONTROLLER_BUTTON_RIGHTSHOULDER)
|
||||
{
|
||||
@@ -292,7 +292,7 @@ static const char* glyph_for_vector(
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return sdlbutton_to_glyph(buttons[index]);
|
||||
return BUTTONGLYPHS_sdlbutton_to_glyph(buttons[index]);
|
||||
}
|
||||
|
||||
const char* BUTTONGLYPHS_get_button(const ActionSet actionset, const Action action, int binding)
|
||||
|
||||
Reference in New Issue
Block a user