mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-03-03 00:55:55 +00:00
Remove menu_entries_get_actiondata_at_offset
This commit is contained in:
parent
df15a67c71
commit
2b55e5858e
@ -209,9 +209,9 @@ static int action_left_mainmenu(unsigned type, const char *label,
|
||||
file_list_t *menu_stack = menu_entries_get_menu_stack_ptr(0);
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_file_list_cbs_t *cbs =
|
||||
menu_entries_get_actiondata_at_offset(selection_buf,
|
||||
selection);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf,
|
||||
selection) : NULL;
|
||||
|
||||
list_info.type = MENU_LIST_HORIZONTAL;
|
||||
list_info.action = MENU_ACTION_LEFT;
|
||||
|
@ -191,7 +191,7 @@ static int action_right_goto_tab(void)
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
file_list_t *menu_stack = menu_entries_get_menu_stack_ptr(0);
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_file_list_cbs_t *cbs = menu_entries_get_actiondata_at_offset(selection_buf, selection);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ? file_list_get_actiondata_at_offset(selection_buf, selection) : NULL;
|
||||
|
||||
list_info.type = MENU_LIST_HORIZONTAL;
|
||||
list_info.action = MENU_ACTION_RIGHT;
|
||||
|
@ -42,7 +42,7 @@ static int action_select_default(const char *path, const char *label, unsigned t
|
||||
menu_entry_init(&entry);
|
||||
menu_entry_get(&entry, 0, idx, NULL, false);
|
||||
|
||||
cbs = menu_entries_get_actiondata_at_offset(selection_buf, idx);
|
||||
cbs = selection_buf ? file_list_get_actiondata_at_offset(selection_buf, idx) : NULL;
|
||||
|
||||
if (!cbs)
|
||||
{
|
||||
|
@ -133,8 +133,9 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
case ITERATE_TYPE_INFO:
|
||||
{
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
menu_file_list_cbs_t *cbs =
|
||||
menu_entries_get_actiondata_at_offset(selection_buf, selection);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf, selection)
|
||||
: NULL;
|
||||
|
||||
if (cbs->enum_idx != MSG_UNKNOWN)
|
||||
{
|
||||
|
@ -44,15 +44,6 @@ void menu_entries_get_at_offset(const file_list_t *list, size_t idx,
|
||||
file_list_get_alt_at_offset(list, idx, alt);
|
||||
}
|
||||
|
||||
menu_file_list_cbs_t *menu_entries_get_actiondata_at_offset(
|
||||
const file_list_t *list, size_t idx)
|
||||
{
|
||||
if (!list)
|
||||
return NULL;
|
||||
return (menu_file_list_cbs_t*)
|
||||
file_list_get_actiondata_at_offset(list, idx);
|
||||
}
|
||||
|
||||
static bool menu_entries_clear(file_list_t *list)
|
||||
{
|
||||
unsigned i;
|
||||
@ -509,8 +500,8 @@ size_t menu_entries_get_size(void)
|
||||
rarch_setting_t *menu_entries_get_setting(uint32_t i)
|
||||
{
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
menu_file_list_cbs_t *cbs =
|
||||
menu_entries_get_actiondata_at_offset(selection_buf, i);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf, i) : NULL;
|
||||
|
||||
if (!cbs)
|
||||
return NULL;
|
||||
|
@ -145,9 +145,6 @@ void menu_entries_get_at_offset(const file_list_t *list, size_t idx,
|
||||
const char **path, const char **label, unsigned *file_type,
|
||||
size_t *entry_idx, const char **alt);
|
||||
|
||||
menu_file_list_cbs_t *menu_entries_get_actiondata_at_offset(
|
||||
const file_list_t *list, size_t idx);
|
||||
|
||||
void menu_entries_set_alt_at_offset(file_list_t *list, size_t idx,
|
||||
const char *alt);
|
||||
|
||||
|
@ -563,13 +563,11 @@ static int menu_input_pointer_post_iterate(
|
||||
void menu_input_post_iterate(int *ret, unsigned action)
|
||||
{
|
||||
menu_entry_t entry;
|
||||
menu_file_list_cbs_t *cbs = NULL;
|
||||
settings_t *settings = config_get_ptr();
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
|
||||
if (selection_buf)
|
||||
cbs = menu_entries_get_actiondata_at_offset(selection_buf, selection);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf, selection) : NULL;
|
||||
|
||||
menu_entry_init(&entry);
|
||||
menu_entry_get(&entry, 0, selection, NULL, false);
|
||||
|
@ -916,8 +916,8 @@ int menu_setting_set(unsigned type, const char *label,
|
||||
int ret = 0;
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_file_list_cbs_t *cbs = menu_entries_get_actiondata_at_offset(
|
||||
selection_buf, selection);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf, selection) : NULL;
|
||||
|
||||
if (!cbs)
|
||||
return 0;
|
||||
|
@ -313,7 +313,7 @@ void menu_entry_get(menu_entry_t *entry, size_t stack_idx,
|
||||
menu_entries_get_at_offset(list, i, &path, &entry_label, &entry->type,
|
||||
&entry->entry_idx, NULL);
|
||||
|
||||
cbs = menu_entries_get_actiondata_at_offset(list, i);
|
||||
cbs = list ? file_list_get_actiondata_at_offset(list, i) : NULL;
|
||||
|
||||
if (cbs)
|
||||
{
|
||||
@ -417,8 +417,8 @@ int menu_entry_action(menu_entry_t *entry, unsigned i, enum menu_action action)
|
||||
int ret = 0;
|
||||
file_list_t *selection_buf =
|
||||
menu_entries_get_selection_buf_ptr(0);
|
||||
menu_file_list_cbs_t *cbs =
|
||||
menu_entries_get_actiondata_at_offset(selection_buf, i);
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
file_list_get_actiondata_at_offset(selection_buf, i) : NULL;
|
||||
|
||||
switch (action)
|
||||
{
|
||||
@ -482,7 +482,7 @@ int menu_entry_action(menu_entry_t *entry, unsigned i, enum menu_action action)
|
||||
break;
|
||||
}
|
||||
|
||||
cbs = menu_entries_get_actiondata_at_offset(selection_buf, i);
|
||||
cbs = selection_buf ? file_list_get_actiondata_at_offset(selection_buf, i) : NULL;
|
||||
|
||||
if (menu_entries_ctl(MENU_ENTRIES_CTL_NEEDS_REFRESH, NULL))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user