(Menu drivers) Start setting up setting pointers
This commit is contained in:
parent
7c6736ae4d
commit
04d54be8df
|
@ -385,12 +385,14 @@ static void glui_frame(void)
|
||||||
const char *path = NULL, *entry_label = NULL;
|
const char *path = NULL, *entry_label = NULL;
|
||||||
unsigned type = 0, w = 0;
|
unsigned type = 0, w = 0;
|
||||||
bool selected = false;
|
bool selected = false;
|
||||||
|
rarch_setting_t *setting = NULL;
|
||||||
|
|
||||||
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
||||||
&entry_label, &type);
|
&entry_label, &type);
|
||||||
rarch_setting_t *setting = (rarch_setting_t*)setting_data_find_setting(
|
setting = (rarch_setting_t*)setting_data_find_setting(
|
||||||
driver.menu->list_settings,
|
driver.menu->list_settings,
|
||||||
driver.menu->menu_list->selection_buf->list[i].label);
|
driver.menu->menu_list->selection_buf->list[i].label);
|
||||||
|
|
||||||
(void)setting;
|
(void)setting;
|
||||||
|
|
||||||
disp_set_label(driver.menu->menu_list->selection_buf, &w, type, i, label,
|
disp_set_label(driver.menu->menu_list->selection_buf, &w, type, i, label,
|
||||||
|
|
|
@ -439,10 +439,11 @@ static void rgui_render(void)
|
||||||
const char *path = NULL, *entry_label = NULL;
|
const char *path = NULL, *entry_label = NULL;
|
||||||
unsigned type = 0, w = 0;
|
unsigned type = 0, w = 0;
|
||||||
bool selected = false;
|
bool selected = false;
|
||||||
|
rarch_setting_t *setting = NULL;
|
||||||
|
|
||||||
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
||||||
&entry_label, &type);
|
&entry_label, &type);
|
||||||
rarch_setting_t *setting = (rarch_setting_t*)setting_data_find_setting(
|
setting = (rarch_setting_t*)setting_data_find_setting(
|
||||||
driver.menu->list_settings,
|
driver.menu->list_settings,
|
||||||
driver.menu->menu_list->selection_buf->list[i].label);
|
driver.menu->menu_list->selection_buf->list[i].label);
|
||||||
(void)setting;
|
(void)setting;
|
||||||
|
|
|
@ -230,15 +230,21 @@ static void rmenu_render(void)
|
||||||
const char *path = NULL, *entry_label = NULL;
|
const char *path = NULL, *entry_label = NULL;
|
||||||
unsigned type = 0, w = 0;
|
unsigned type = 0, w = 0;
|
||||||
bool selected = false;
|
bool selected = false;
|
||||||
|
rarch_setting_t *setting = NULL;
|
||||||
|
|
||||||
menu_list_get_at_offset(menu->menu_list->selection_buf, i,
|
menu_list_get_at_offset(menu->menu_list->selection_buf, i,
|
||||||
&path, &entry_label, &type);
|
&path, &entry_label, &type);
|
||||||
|
|
||||||
|
setting = (rarch_setting_t*)setting_data_find_setting(
|
||||||
|
driver.menu->list_settings,
|
||||||
|
driver.menu->menu_list->selection_buf->list[i].label);
|
||||||
|
(void)setting;
|
||||||
|
|
||||||
disp_set_label(menu->menu_list->selection_buf, &w, type, i, label,
|
disp_set_label(menu->menu_list->selection_buf, &w, type, i, label,
|
||||||
type_str, sizeof(type_str),
|
type_str, sizeof(type_str),
|
||||||
entry_label, path,
|
entry_label, path,
|
||||||
path_buf, sizeof(path_buf));
|
path_buf, sizeof(path_buf));
|
||||||
|
|
||||||
selected = (i == driver.menu->selection_ptr);
|
selected = (i == driver.menu->selection_ptr);
|
||||||
|
|
||||||
menu_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (w + 1 + 2),
|
menu_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (w + 1 + 2),
|
||||||
|
|
|
@ -577,25 +577,31 @@ static void rmenu_xui_render(void)
|
||||||
|
|
||||||
end = menu_list_get_size(driver.menu->menu_list);
|
end = menu_list_get_size(driver.menu->menu_list);
|
||||||
for (i = 0; i < end; i++)
|
for (i = 0; i < end; i++)
|
||||||
{
|
{
|
||||||
wchar_t msg_left[PATH_MAX_LENGTH], msg_right[PATH_MAX_LENGTH];
|
wchar_t msg_left[PATH_MAX_LENGTH], msg_right[PATH_MAX_LENGTH];
|
||||||
char type_str[PATH_MAX_LENGTH], path_buf[PATH_MAX_LENGTH];
|
char type_str[PATH_MAX_LENGTH], path_buf[PATH_MAX_LENGTH];
|
||||||
const char *path = NULL, *entry_label = NULL;
|
const char *path = NULL, *entry_label = NULL;
|
||||||
unsigned type = 0, w = 0;
|
unsigned type = 0, w = 0;
|
||||||
|
rarch_setting_t *setting = NULL;
|
||||||
|
|
||||||
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
menu_list_get_at_offset(driver.menu->menu_list->selection_buf, i, &path,
|
||||||
&entry_label, &type);
|
&entry_label, &type);
|
||||||
|
|
||||||
disp_set_label(driver.menu->menu_list->selection_buf,
|
setting = (rarch_setting_t*)setting_data_find_setting(
|
||||||
&w, type, i, label,
|
driver.menu->list_settings,
|
||||||
type_str, sizeof(type_str),
|
driver.menu->menu_list->selection_buf->list[i].label);
|
||||||
entry_label, path,
|
(void)setting;
|
||||||
path_buf, sizeof(path_buf));
|
|
||||||
|
|
||||||
mbstowcs(msg_left, path_buf, sizeof(msg_left) / sizeof(wchar_t));
|
disp_set_label(driver.menu->menu_list->selection_buf,
|
||||||
mbstowcs(msg_right, type_str, sizeof(msg_right) / sizeof(wchar_t));
|
&w, type, i, label,
|
||||||
rmenu_xui_set_list_text(i, msg_left, msg_right);
|
type_str, sizeof(type_str),
|
||||||
}
|
entry_label, path,
|
||||||
|
path_buf, sizeof(path_buf));
|
||||||
|
|
||||||
|
mbstowcs(msg_left, path_buf, sizeof(msg_left) / sizeof(wchar_t));
|
||||||
|
mbstowcs(msg_right, type_str, sizeof(msg_right) / sizeof(wchar_t));
|
||||||
|
rmenu_xui_set_list_text(i, msg_left, msg_right);
|
||||||
|
}
|
||||||
XuiListSetCurSelVisible(m_menulist, driver.menu->selection_ptr);
|
XuiListSetCurSelVisible(m_menulist, driver.menu->selection_ptr);
|
||||||
|
|
||||||
if (driver.menu->keyboard.display)
|
if (driver.menu->keyboard.display)
|
||||||
|
|
|
@ -877,10 +877,16 @@ static void xmb_draw_items(file_list_t *list, file_list_t *stack,
|
||||||
const char *path = NULL, *entry_label = NULL;
|
const char *path = NULL, *entry_label = NULL;
|
||||||
unsigned type = 0, w = 0;
|
unsigned type = 0, w = 0;
|
||||||
xmb_node_t *node = NULL;
|
xmb_node_t *node = NULL;
|
||||||
|
rarch_setting_t *setting = NULL;
|
||||||
|
|
||||||
menu_list_get_at_offset(list, i, &path, &entry_label, &type);
|
menu_list_get_at_offset(list, i, &path, &entry_label, &type);
|
||||||
node = (xmb_node_t*)file_list_get_userdata_at_offset(list, i);
|
node = (xmb_node_t*)file_list_get_userdata_at_offset(list, i);
|
||||||
|
|
||||||
|
setting = (rarch_setting_t*)setting_data_find_setting(
|
||||||
|
driver.menu->list_settings,
|
||||||
|
driver.menu->menu_list->selection_buf->list[i].label);
|
||||||
|
(void)setting;
|
||||||
|
|
||||||
disp_set_label(list, &w, type, i, label,
|
disp_set_label(list, &w, type, i, label,
|
||||||
val_buf, sizeof(val_buf),
|
val_buf, sizeof(val_buf),
|
||||||
entry_label, path,
|
entry_label, path,
|
||||||
|
|
Loading…
Reference in New Issue