mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-24 00:20:01 +00:00
We can now get rid of menu_setting_get_label
This commit is contained in:
parent
f6dc06ac10
commit
6419ed08cc
@ -1374,11 +1374,14 @@ static void menu_action_setting_disp_set_label_achievement_information(
|
||||
const char *path,
|
||||
char *s2, size_t len2)
|
||||
{
|
||||
*s = '\0';
|
||||
*w = 2;
|
||||
menu_file_list_cbs_t *cbs = list->list[i].actiondata;
|
||||
rarch_setting_t *setting = cbs->setting;
|
||||
|
||||
menu_setting_get_label(list, s,
|
||||
len, w, type, label, i);
|
||||
*s = '\0';
|
||||
*w = 2;
|
||||
|
||||
if (setting && setting->get_string_representation)
|
||||
setting->get_string_representation(setting, s, len);
|
||||
|
||||
strlcpy(s2, path, len2);
|
||||
}
|
||||
@ -1466,11 +1469,14 @@ static void menu_action_setting_disp_set_label(file_list_t* list,
|
||||
const char *path,
|
||||
char *s2, size_t len2)
|
||||
{
|
||||
*s = '\0';
|
||||
*w = 19;
|
||||
menu_file_list_cbs_t *cbs = list->list[i].actiondata;
|
||||
rarch_setting_t *setting = cbs->setting;
|
||||
|
||||
menu_setting_get_label(list, s,
|
||||
len, w, type, label, i);
|
||||
*s = '\0';
|
||||
*w = 19;
|
||||
|
||||
if (setting && setting->get_string_representation)
|
||||
setting->get_string_representation(setting, s, len);
|
||||
|
||||
strlcpy(s2, path, len2);
|
||||
}
|
||||
|
@ -6577,35 +6577,6 @@ static void get_string_representation_bind_device(rarch_setting_t *setting, char
|
||||
strlcpy(s, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISABLED), len);
|
||||
}
|
||||
|
||||
/**
|
||||
* menu_setting_get_label:
|
||||
* @list : File list on which to perform the search
|
||||
* @s : String for the type to be represented on-screen as
|
||||
* a label.
|
||||
* @len : Size of @s
|
||||
* @w : Width of the string (for text label representation
|
||||
* purposes in the menu display driver).
|
||||
* @type : Identifier of setting.
|
||||
* @menu_label : Menu Label identifier of setting.
|
||||
* @label : Label identifier of setting.
|
||||
* @idx : Index identifier of setting.
|
||||
*
|
||||
* Get associated label of a setting.
|
||||
**/
|
||||
void menu_setting_get_label(file_list_t *list, char *s,
|
||||
size_t len, unsigned *w, unsigned type,
|
||||
const char *menu_label, unsigned idx)
|
||||
{
|
||||
rarch_setting_t *setting = NULL;
|
||||
if (!list)
|
||||
return;
|
||||
|
||||
setting = menu_setting_find(list->list[idx].label);
|
||||
|
||||
if (setting && setting->get_string_representation)
|
||||
setting->get_string_representation(setting, s, len);
|
||||
}
|
||||
|
||||
void general_read_handler(rarch_setting_t *setting)
|
||||
{
|
||||
settings_t *settings = config_get_ptr();
|
||||
|
@ -102,25 +102,6 @@ rarch_setting_t *menu_setting_find_enum(enum msg_hash_enums enum_idx);
|
||||
**/
|
||||
void menu_setting_get_string_representation(rarch_setting_t *setting, char *s, size_t len);
|
||||
|
||||
/**
|
||||
* menu_setting_get_label:
|
||||
* @list : File list on which to perform the search
|
||||
* @s : String for the type to be represented on-screen as
|
||||
* a label.
|
||||
* @len : Size of @s.
|
||||
* @w : Width of the string (for text label representation
|
||||
* purposes in the menu display driver).
|
||||
* @type : Identifier of setting.
|
||||
* @menu_label : Menu Label identifier of setting.
|
||||
* @label : Label identifier of setting.
|
||||
* @idx : Index identifier of setting.
|
||||
*
|
||||
* Get associated label of a setting.
|
||||
**/
|
||||
void menu_setting_get_label(file_list_t *list, char *s,
|
||||
size_t len, unsigned *w, unsigned type,
|
||||
const char *menu_label, unsigned idx);
|
||||
|
||||
int menu_action_handle_setting(rarch_setting_t *setting,
|
||||
unsigned type, unsigned action, bool wraparound);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user