- [NEW] Es pot accedir al dialeg de configuracio dels joysticks des del menú

This commit is contained in:
2025-08-16 11:23:16 +02:00
parent 8201d51668
commit 1fdfeedacc
4 changed files with 25 additions and 4 deletions

View File

@@ -31,6 +31,7 @@ namespace ui
std::vector<menu_t> menus;
int visible_menu = -1;
int menu_x = 0;
bool do_not_exit = false;
void init()
{
@@ -81,7 +82,8 @@ namespace ui
if (ui::getClicked())
{
if (option.callback) option.value = option.callback(option.value);
if (exit_callback) exit_callback();
if (exit_callback && !do_not_exit) exit_callback();
do_not_exit = false;
return;
}
}
@@ -103,6 +105,11 @@ namespace ui
exit_callback = callback;
}
void exitButNotContinue()
{
do_not_exit = true;
}
const int addsubmenu(const char *label)
{
menu_t m;