mirror of
https://github.com/libretro/RetroArch
synced 2025-04-03 10:21:31 +00:00
(Menu) Refactor MENU_SETTINGS_VIDEO_OPTIONS
This commit is contained in:
parent
fac795f796
commit
e77ba49b3a
@ -1823,7 +1823,7 @@ static int menu_action_ok(const char *dir,
|
|||||||
&& type == MENU_FILE_PLAIN)
|
&& type == MENU_FILE_PLAIN)
|
||||||
{
|
{
|
||||||
menu_common_setting_set_current_string_path(setting, dir, path);
|
menu_common_setting_set_current_string_path(setting, dir, path);
|
||||||
menu_flush_stack_type(driver.menu->menu_stack,MENU_SETTINGS_VIDEO_OPTIONS);
|
menu_flush_stack_label(driver.menu->menu_stack, "Video Options");
|
||||||
}
|
}
|
||||||
else if (setting && !strcmp(setting->name, "audio_dsp_plugin")
|
else if (setting && !strcmp(setting->name, "audio_dsp_plugin")
|
||||||
&& type == MENU_FILE_PLAIN)
|
&& type == MENU_FILE_PLAIN)
|
||||||
|
@ -13,7 +13,7 @@ static void get_title(const char *label, const char *dir,
|
|||||||
snprintf(title, sizeof_title, "CONFIG %s", dir);
|
snprintf(title, sizeof_title, "CONFIG %s", dir);
|
||||||
else if (menu_type == MENU_SETTINGS_DISK_APPEND)
|
else if (menu_type == MENU_SETTINGS_DISK_APPEND)
|
||||||
snprintf(title, sizeof_title, "DISK APPEND %s", dir);
|
snprintf(title, sizeof_title, "DISK APPEND %s", dir);
|
||||||
else if (menu_type == MENU_SETTINGS_VIDEO_OPTIONS)
|
else if (!strcmp(label, "Video Options"))
|
||||||
strlcpy(title, "VIDEO OPTIONS", sizeof_title);
|
strlcpy(title, "VIDEO OPTIONS", sizeof_title);
|
||||||
else if (!strcmp(label, "Input Options") ||
|
else if (!strcmp(label, "Input Options") ||
|
||||||
menu_type == MENU_SETTINGS_CUSTOM_BIND ||
|
menu_type == MENU_SETTINGS_CUSTOM_BIND ||
|
||||||
|
@ -647,7 +647,7 @@ unsigned menu_common_type_is(const char *label, unsigned type)
|
|||||||
!strcmp(label, "General Options") ||
|
!strcmp(label, "General Options") ||
|
||||||
!strcmp(label, "core_options") ||
|
!strcmp(label, "core_options") ||
|
||||||
!strcmp(label, "core_information") ||
|
!strcmp(label, "core_information") ||
|
||||||
type == MENU_SETTINGS_VIDEO_OPTIONS ||
|
!strcmp(label, "Video Options") ||
|
||||||
type == MENU_SETTINGS_FONT_OPTIONS ||
|
type == MENU_SETTINGS_FONT_OPTIONS ||
|
||||||
type == MENU_SETTINGS_SHADER_OPTIONS ||
|
type == MENU_SETTINGS_SHADER_OPTIONS ||
|
||||||
type == MENU_SETTINGS_SHADER_PARAMETERS ||
|
type == MENU_SETTINGS_SHADER_PARAMETERS ||
|
||||||
|
@ -87,8 +87,7 @@ typedef enum
|
|||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
// Shader stuff
|
// Shader stuff
|
||||||
MENU_SETTINGS_VIDEO_OPTIONS = MENU_SETTINGS + 1,
|
MENU_SETTINGS_VIDEO_RESOLUTION = MENU_SETTINGS + 1,
|
||||||
MENU_SETTINGS_VIDEO_RESOLUTION,
|
|
||||||
MENU_SETTINGS_CUSTOM_VIEWPORT,
|
MENU_SETTINGS_CUSTOM_VIEWPORT,
|
||||||
MENU_SETTINGS_FONT_OPTIONS,
|
MENU_SETTINGS_FONT_OPTIONS,
|
||||||
MENU_SETTINGS_SHADER_OPTIONS,
|
MENU_SETTINGS_SHADER_OPTIONS,
|
||||||
|
@ -393,6 +393,42 @@ int menu_entries_push_list(menu_handle_t *menu,
|
|||||||
add_setting_entry(menu,list,"location_driver", 0, setting_data);
|
add_setting_entry(menu,list,"location_driver", 0, setting_data);
|
||||||
add_setting_entry(menu,list,"menu_driver", 0, setting_data);
|
add_setting_entry(menu,list,"menu_driver", 0, setting_data);
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(label, "Video Options"))
|
||||||
|
{
|
||||||
|
file_list_clear(list);
|
||||||
|
add_setting_entry(menu,list,"video_shared_context", 0, setting_data);
|
||||||
|
#if defined(GEKKO) || defined(__CELLOS_LV2__)
|
||||||
|
file_list_push(list, "Screen Resolution", "",
|
||||||
|
MENU_SETTINGS_VIDEO_RESOLUTION, 0);
|
||||||
|
#endif
|
||||||
|
add_setting_entry(menu,list,"video_viwidth", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_filter", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list, "pal60_enable", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_smooth", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list, "soft_filter", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_gamma", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_filter_flicker", 0,
|
||||||
|
setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_scale_integer", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"aspect_ratio_index", 0, setting_data);
|
||||||
|
file_list_push(list, "Custom Ratio", "",
|
||||||
|
MENU_SETTINGS_CUSTOM_VIEWPORT, 0);
|
||||||
|
add_setting_entry(menu,list,"video_fullscreen", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_windowed_fullscreen", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_rotation", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_vsync", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_hard_sync", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_hard_sync_frames", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_frame_delay", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_black_frame_insertion", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_swap_interval", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_threaded", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_scale", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_crop_overscan", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_monitor_index", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_refresh_rate", 0, setting_data);
|
||||||
|
add_setting_entry(menu,list,"video_refresh_rate_auto", 0, setting_data);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
switch (menu_type)
|
switch (menu_type)
|
||||||
@ -454,41 +490,6 @@ int menu_entries_push_list(menu_handle_t *menu,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case MENU_SETTINGS_VIDEO_OPTIONS:
|
|
||||||
file_list_clear(list);
|
|
||||||
add_setting_entry(menu,list,"video_shared_context", 0, setting_data);
|
|
||||||
#if defined(GEKKO) || defined(__CELLOS_LV2__)
|
|
||||||
file_list_push(list, "Screen Resolution", "",
|
|
||||||
MENU_SETTINGS_VIDEO_RESOLUTION, 0);
|
|
||||||
#endif
|
|
||||||
add_setting_entry(menu,list,"video_viwidth", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_filter", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list, "pal60_enable", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_smooth", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list, "soft_filter", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_gamma", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_filter_flicker", 0,
|
|
||||||
setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_scale_integer", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"aspect_ratio_index", 0, setting_data);
|
|
||||||
file_list_push(list, "Custom Ratio", "",
|
|
||||||
MENU_SETTINGS_CUSTOM_VIEWPORT, 0);
|
|
||||||
add_setting_entry(menu,list,"video_fullscreen", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_windowed_fullscreen", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_rotation", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_vsync", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_hard_sync", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_hard_sync_frames", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_frame_delay", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_black_frame_insertion", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_swap_interval", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_threaded", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_scale", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_crop_overscan", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_monitor_index", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_refresh_rate", 0, setting_data);
|
|
||||||
add_setting_entry(menu,list,"video_refresh_rate_auto", 0, setting_data);
|
|
||||||
break;
|
|
||||||
case MENU_SETTINGS_FONT_OPTIONS:
|
case MENU_SETTINGS_FONT_OPTIONS:
|
||||||
file_list_clear(list);
|
file_list_clear(list);
|
||||||
add_setting_entry(menu,list,"video_font_enable", 0, setting_data);
|
add_setting_entry(menu,list,"video_font_enable", 0, setting_data);
|
||||||
@ -498,7 +499,7 @@ int menu_entries_push_list(menu_handle_t *menu,
|
|||||||
file_list_clear(list);
|
file_list_clear(list);
|
||||||
add_setting_entry(menu,list,"Driver Options", MENU_FILE_SWITCH, setting_data);
|
add_setting_entry(menu,list,"Driver Options", MENU_FILE_SWITCH, setting_data);
|
||||||
add_setting_entry(menu,list,"General Options", MENU_FILE_SWITCH, setting_data);
|
add_setting_entry(menu,list,"General Options", MENU_FILE_SWITCH, setting_data);
|
||||||
add_setting_entry(menu,list,"Video Options", MENU_SETTINGS_VIDEO_OPTIONS, setting_data);
|
add_setting_entry(menu,list,"Video Options", MENU_FILE_SWITCH, setting_data);
|
||||||
add_setting_entry(menu,list,"Shader Options", MENU_SETTINGS_SHADER_OPTIONS, setting_data);
|
add_setting_entry(menu,list,"Shader Options", MENU_SETTINGS_SHADER_OPTIONS, setting_data);
|
||||||
add_setting_entry(menu,list,"Font Options", MENU_SETTINGS_FONT_OPTIONS, setting_data);
|
add_setting_entry(menu,list,"Font Options", MENU_SETTINGS_FONT_OPTIONS, setting_data);
|
||||||
add_setting_entry(menu,list,"Audio Options", MENU_FILE_SWITCH, setting_data);
|
add_setting_entry(menu,list,"Audio Options", MENU_FILE_SWITCH, setting_data);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user