From eabe17251a0d3b1915c8b3eb794a233f0322dfba Mon Sep 17 00:00:00 2001 From: Xottab-DUTY Date: Thu, 9 Jan 2025 02:41:28 +0300 Subject: [PATCH] Improved gamepad navigation in the game UI (#943) Support for stick navigation --- res/gamedata/configs/ui/ui_mm_load_dlg.xml | 6 +-- res/gamedata/configs/ui/ui_mm_load_dlg_16.xml | 6 +-- res/gamedata/configs/ui/ui_mm_opt.xml | 28 +++++------ res/gamedata/configs/ui/ui_mm_opt_16.xml | 26 +++++------ res/gamedata/configs/ui/ui_mm_save_dlg.xml | 6 +-- res/gamedata/configs/ui/ui_mm_save_dlg_16.xml | 6 +-- res/gamedata/scripts/ui_load_dialog.script | 8 +++- res/gamedata/scripts/ui_main_menu.script | 5 +- res/gamedata/scripts/ui_mm_mp_gamespy.script | 10 +++- res/gamedata/scripts/ui_mm_mp_localnet.script | 7 ++- res/gamedata/scripts/ui_mm_opt_main.script | 2 + res/gamedata/scripts/ui_mp_main.script | 7 ++- res/gamedata/scripts/ui_numpad.script | 21 ++++++++- res/gamedata/scripts/ui_save_dialog.script | 10 ++-- res/gamedata/scripts/ui_sleep_dialog.script | 5 +- src/xrGame/UIDialogHolder.cpp | 46 +++++++++++++++++++ src/xrGame/ui/UIDialogWnd.h | 2 +- src/xrGame/ui/UIMMShniaga.cpp | 10 ++-- src/xrUICore/ListBox/UIListBoxItem.cpp | 6 +++ src/xrUICore/ListBox/UIListBoxItem.h | 1 + src/xrUICore/ListWnd/UIListItem.cpp | 2 + 21 files changed, 162 insertions(+), 58 deletions(-) diff --git a/res/gamedata/configs/ui/ui_mm_load_dlg.xml b/res/gamedata/configs/ui/ui_mm_load_dlg.xml index 006e8370a17..a1226770e04 100644 --- a/res/gamedata/configs/ui/ui_mm_load_dlg.xml +++ b/res/gamedata/configs/ui/ui_mm_load_dlg.xml @@ -41,15 +41,15 @@ - + ui_inGame2_Mp_bigbuttone ui_mm_load - + ui_inGame2_Mp_bigbuttone ui_mm_delete - + ui_inGame2_Mp_bigbuttone ui_mm_cancel diff --git a/res/gamedata/configs/ui/ui_mm_load_dlg_16.xml b/res/gamedata/configs/ui/ui_mm_load_dlg_16.xml index da0ca100fdb..8d88d7ef145 100644 --- a/res/gamedata/configs/ui/ui_mm_load_dlg_16.xml +++ b/res/gamedata/configs/ui/ui_mm_load_dlg_16.xml @@ -47,15 +47,15 @@ - + ui_inGame2_Mp_bigbuttone ui_mm_load - + ui_inGame2_Mp_bigbuttone ui_mm_delete - + ui_inGame2_Mp_bigbuttone ui_mm_cancel diff --git a/res/gamedata/configs/ui/ui_mm_opt.xml b/res/gamedata/configs/ui/ui_mm_opt.xml index ed8b11ab049..4e76b90b0e8 100644 --- a/res/gamedata/configs/ui/ui_mm_opt.xml +++ b/res/gamedata/configs/ui/ui_mm_opt.xml @@ -19,7 +19,7 @@ - + ui_mm_apply ui_inGame2_Mp_bigbuttone @@ -27,7 +27,7 @@ - + ui_mm_cancel ui_inGame2_Mp_bigbuttone @@ -35,8 +35,8 @@ - - - - - - - -