From 63c99363bd8da77dce7ce8273d6c5e7e4cbd2261 Mon Sep 17 00:00:00 2001 From: orbea Date: Sun, 8 Apr 2018 08:01:26 -0700 Subject: [PATCH] Hide the 'Core delete' option if the 'Core updater' is also hidden. --- menu/menu_displaylist.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index 66f3756e96..ef80c047b4 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -153,6 +153,7 @@ static int menu_displaylist_parse_core_info(menu_displaylist_info_t *info) unsigned i; char tmp[PATH_MAX_LENGTH]; core_info_t *core_info = NULL; + settings_t *settings = config_get_ptr(); tmp[0] = '\0'; @@ -336,11 +337,12 @@ static int menu_displaylist_parse_core_info(menu_displaylist_info_t *info) } } - menu_entries_append_enum(info->list, - msg_hash_to_str(MENU_ENUM_LABEL_VALUE_CORE_DELETE), - msg_hash_to_str(MENU_ENUM_LABEL_CORE_DELETE), - MENU_ENUM_LABEL_CORE_DELETE, - MENU_SETTING_ACTION_CORE_DELETE, 0, 0); + if (settings->bools.menu_show_core_updater) + menu_entries_append_enum(info->list, + msg_hash_to_str(MENU_ENUM_LABEL_VALUE_CORE_DELETE), + msg_hash_to_str(MENU_ENUM_LABEL_CORE_DELETE), + MENU_ENUM_LABEL_CORE_DELETE, + MENU_SETTING_ACTION_CORE_DELETE, 0, 0); return 0; }