(Menu) Refactor MENU_SETTINGS_PRIVACY_OPTIONS

This commit is contained in:
twinaphex 2014-09-04 18:09:25 +02:00
parent 59ff9a1620
commit 8366ea976b
4 changed files with 10 additions and 10 deletions

View File

@ -57,7 +57,7 @@ static void get_title(const char *label, const char *dir,
strlcpy(title, "CORE OPTIONS", sizeof_title);
else if (!strcmp(label, "core_information"))
strlcpy(title, "CORE INFO", sizeof_title);
else if (menu_type == MENU_SETTINGS_PRIVACY_OPTIONS)
else if (!strcmp(label, "Privacy Options"))
strlcpy(title, "PRIVACY OPTIONS", sizeof_title);
#ifdef HAVE_SHADER_MANAGER
else if (!strcmp(label, "video_shader_pass"))

View File

@ -655,7 +655,7 @@ unsigned menu_common_type_is(const char *label, unsigned type)
type == MENU_SETTINGS_AUDIO_OPTIONS ||
type == MENU_SETTINGS_DISK_OPTIONS ||
type == MENU_SETTINGS_PATH_OPTIONS ||
type == MENU_SETTINGS_PRIVACY_OPTIONS ||
!strcmp(label, "Privacy Options") ||
type == MENU_SETTINGS_OVERLAY_OPTIONS ||
!strcmp(label, "User Options") ||
!strcmp(label, "Netplay Options") ||

View File

@ -113,7 +113,6 @@ typedef enum
MENU_SETTINGS_INPUT_OPTIONS,
MENU_SETTINGS_PATH_OPTIONS,
MENU_SETTINGS_OVERLAY_OPTIONS,
MENU_SETTINGS_PRIVACY_OPTIONS,
MENU_SETTINGS_OPTIONS,
MENU_SETTINGS_DRIVERS,
MENU_SETTINGS_DISK_OPTIONS,

View File

@ -315,6 +315,12 @@ int menu_entries_push_list(menu_handle_t *menu,
menu_entries_push_perfcounter(menu, list, perf_counters_rarch,
perf_ptr_rarch, MENU_SETTINGS_PERF_COUNTERS_BEGIN);
}
else if (!strcmp(label, "Privacy Options"))
{
file_list_clear(list);
add_setting_entry(menu,list,"camera_allow", 0, setting_data);
add_setting_entry(menu,list,"location_allow", 0, setting_data);
}
else
{
switch (menu_type)
@ -453,13 +459,8 @@ int menu_entries_push_list(menu_handle_t *menu,
file_list_push(list, "Disk Options", "",
MENU_SETTINGS_DISK_OPTIONS, 0);
}
add_setting_entry(menu,list,"Privacy Options", MENU_SETTINGS_PRIVACY_OPTIONS,
setting_data);
break;
case MENU_SETTINGS_PRIVACY_OPTIONS:
file_list_clear(list);
add_setting_entry(menu,list,"camera_allow", 0, setting_data);
add_setting_entry(menu,list,"location_allow", 0, setting_data);
add_setting_entry(menu,list,"Privacy Options",
MENU_FILE_SWITCH, setting_data);
break;
case MENU_SETTINGS_DISK_OPTIONS:
file_list_clear(list);