(Input Mapping/Remapping) Restore broken 'reset to default' functionality

This commit is contained in:
jdgleaver 2020-05-19 11:35:57 +01:00
parent 54fd445c75
commit 5e904c4dc3
4 changed files with 25 additions and 11 deletions

View File

@ -194,7 +194,6 @@ static int action_scan_input_desc(const char *path,
static int menu_cbs_init_bind_scan_compare_type(menu_file_list_cbs_t *cbs,
unsigned type)
{
switch (type)
{
#ifdef HAVE_LIBRETRODB
@ -208,7 +207,7 @@ static int menu_cbs_init_bind_scan_compare_type(menu_file_list_cbs_t *cbs,
#endif
case FILE_TYPE_RPL_ENTRY:
BIND_ACTION_SCAN(cbs, action_switch_thumbnail);
break;
return 0;
case FILE_TYPE_NONE:
default:

View File

@ -549,7 +549,7 @@ static int menu_cbs_init_bind_start_compare_label(menu_file_list_cbs_t *cbs)
}
}
return 0;
return -1;
}
static int menu_cbs_init_bind_start_compare_type(menu_file_list_cbs_t *cbs,

View File

@ -8049,10 +8049,22 @@ static enum menu_action materialui_parse_menu_entry_action(
materialui_auto_select_onscreen_entry(mui, MUI_ONSCREEN_ENTRY_FIRST);
break;
case MENU_ACTION_SCAN:
/* 'Scan' command is used to cycle current
* thumbnail view mode */
materialui_switch_list_view(mui);
new_action = MENU_ACTION_NOOP;
/* - If this is a playlist, 'scan' command is used
* to cycle current thumbnail view
* - If this is not a playlist, perform default
* 'scan' action *if* current selection is
* on screen */
{
size_t selection = menu_navigation_get_selection();
if (mui->is_playlist)
{
materialui_switch_list_view(mui);
new_action = MENU_ACTION_NOOP;
}
else if (!materialui_entry_onscreen(mui, selection))
new_action = MENU_ACTION_NOOP;
}
break;
case MENU_ACTION_START:
/* - If this is a playlist, attempt to show

View File

@ -5403,10 +5403,13 @@ static enum menu_action rgui_parse_menu_entry_action(
switch (action)
{
case MENU_ACTION_SCAN:
/* 'Scan' command is used to toggle
* fullscreen thumbnail view */
rgui_toggle_fs_thumbnail(rgui);
new_action = MENU_ACTION_NOOP;
/* If this is a playlist, 'scan' command is
* used to toggle fullscreen thumbnail view */
if (rgui->is_playlist)
{
rgui_toggle_fs_thumbnail(rgui);
new_action = MENU_ACTION_NOOP;
}
break;
default:
/* In all other cases, pass through input