Add another label

This commit is contained in:
twinaphex 2016-10-20 17:45:35 +02:00
parent 838cae65c3
commit 1b829e3159
3 changed files with 19 additions and 4 deletions

View File

@ -3024,10 +3024,11 @@ const char *msg_hash_to_str_us(enum msg_hash_enums msg)
switch (msg)
{
case MENU_ENUM_SUBLABEL_VIDEO_SETTINGS:
return "Adjusts settings for video output";
return "Adjusts settings for video output.";
case MENU_ENUM_SUBLABEL_AUDIO_SETTINGS:
return "Adjusts settings for audio output";
return "Adjusts settings for audio output.";
case MENU_ENUM_SUBLABEL_SUSPEND_SCREENSAVER_ENABLE:
return "Prevents your system's screensaver from becoming active.";
case MSG_VALUE_SHUTTING_DOWN:
return "Shutting down";
case MSG_VALUE_REBOOTING:

View File

@ -46,6 +46,16 @@ static int action_bind_sublabel_video_settings_list(
return 0;
}
static int action_bind_sublabel_suspend_screensaver_enable(
file_list_t *list,
unsigned type, unsigned i,
const char *label, const char *path,
char *s, size_t len)
{
strlcpy(s, msg_hash_to_str(MENU_ENUM_SUBLABEL_SUSPEND_SCREENSAVER_ENABLE), len);
return 0;
}
static int action_bind_sublabel_audio_settings_list(
file_list_t *list,
unsigned type, unsigned i,
@ -74,6 +84,9 @@ int menu_cbs_init_bind_sublabel(menu_file_list_cbs_t *cbs,
case MENU_ENUM_LABEL_AUDIO_SETTINGS:
BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_audio_settings_list);
break;
case MENU_ENUM_LABEL_SUSPEND_SCREENSAVER_ENABLE:
BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_suspend_screensaver_enable);
break;
default:
case MSG_UNKNOWN:
return -1;

View File

@ -1858,7 +1858,8 @@ enum msg_hash_enums
MENU_ENUM_LABEL_CB_CORE_THUMBNAILS_DOWNLOAD,
MENU_ENUM_SUBLABEL_VIDEO_SETTINGS,
MENU_ENUM_SUBLABEL_AUDIO_SETTINGS
MENU_ENUM_SUBLABEL_AUDIO_SETTINGS,
MENU_ENUM_SUBLABEL_SUSPEND_SCREENSAVER_ENABLE
};