Move menu_action_setting_set_current_string to menu_entries_cbs.c
This commit is contained in:
parent
7f3c1a9f33
commit
576a362032
|
@ -52,23 +52,6 @@ int setting_handler(
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int menu_action_setting_set_current_string(
|
|
||||||
rarch_setting_t *setting, const char *str)
|
|
||||||
{
|
|
||||||
strlcpy(setting->value.string, str, setting->size);
|
|
||||||
|
|
||||||
if (setting->change_handler)
|
|
||||||
setting->change_handler(setting);
|
|
||||||
|
|
||||||
if (setting->flags & SD_FLAG_EXIT
|
|
||||||
&& setting->cmd_trigger.triggered)
|
|
||||||
{
|
|
||||||
setting->cmd_trigger.triggered = false;
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
int menu_action_set_current_string_based_on_label(
|
int menu_action_set_current_string_based_on_label(
|
||||||
const char *label, const char *str)
|
const char *label, const char *str)
|
||||||
|
|
|
@ -113,6 +113,24 @@ unsigned menu_gx_resolutions[GX_RESOLUTIONS_LAST][2] = {
|
||||||
unsigned menu_current_gx_resolution = GX_RESOLUTIONS_640_480;
|
unsigned menu_current_gx_resolution = GX_RESOLUTIONS_640_480;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
int menu_action_setting_set_current_string(
|
||||||
|
rarch_setting_t *setting, const char *str)
|
||||||
|
{
|
||||||
|
strlcpy(setting->value.string, str, setting->size);
|
||||||
|
|
||||||
|
if (setting->change_handler)
|
||||||
|
setting->change_handler(setting);
|
||||||
|
|
||||||
|
if (setting->flags & SD_FLAG_EXIT
|
||||||
|
&& setting->cmd_trigger.triggered)
|
||||||
|
{
|
||||||
|
setting->cmd_trigger.triggered = false;
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
static void common_load_content(bool persist)
|
static void common_load_content(bool persist)
|
||||||
{
|
{
|
||||||
rarch_main_command(persist ? RARCH_CMD_LOAD_CONTENT_PERSIST : RARCH_CMD_LOAD_CONTENT);
|
rarch_main_command(persist ? RARCH_CMD_LOAD_CONTENT_PERSIST : RARCH_CMD_LOAD_CONTENT);
|
||||||
|
|
Loading…
Reference in New Issue