From c55b9c8c22dc4a25ccf0cd54482860e925da9390 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 5 Nov 2018 14:23:17 +0100 Subject: [PATCH] Add 'No Videos Available' / 'No Images Available' text --- intl/msg_hash_ar.h | 8 ++++++++ intl/msg_hash_chs.h | 8 ++++++++ intl/msg_hash_cht.h | 8 ++++++++ intl/msg_hash_de.h | 8 ++++++++ intl/msg_hash_el.h | 8 ++++++++ intl/msg_hash_eo.h | 8 ++++++++ intl/msg_hash_es.h | 8 ++++++++ intl/msg_hash_fr.h | 8 ++++++++ intl/msg_hash_it.h | 8 ++++++++ intl/msg_hash_ja.h | 8 ++++++++ intl/msg_hash_ko.h | 8 ++++++++ intl/msg_hash_lbl.h | 4 ++++ intl/msg_hash_nl.h | 8 ++++++++ intl/msg_hash_pl.h | 8 ++++++++ intl/msg_hash_pt_br.h | 8 ++++++++ intl/msg_hash_pt_pt.h | 8 ++++++++ intl/msg_hash_ru.h | 8 ++++++++ intl/msg_hash_us.h | 8 ++++++++ intl/msg_hash_vn.h | 8 ++++++++ menu/menu_displaylist.c | 22 ++++++++++++++-------- msg_hash.h | 2 ++ 21 files changed, 164 insertions(+), 8 deletions(-) diff --git a/intl/msg_hash_ar.h b/intl/msg_hash_ar.h index 660389873a..534f04c162 100644 --- a/intl/msg_hash_ar.h +++ b/intl/msg_hash_ar.h @@ -3710,3 +3710,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_chs.h b/intl/msg_hash_chs.h index b3bd91ca77..87804073cb 100644 --- a/intl/msg_hash_chs.h +++ b/intl/msg_hash_chs.h @@ -4729,3 +4729,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_cht.h b/intl/msg_hash_cht.h index 49c14a78c2..37b1f788b0 100644 --- a/intl/msg_hash_cht.h +++ b/intl/msg_hash_cht.h @@ -3486,3 +3486,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_de.h b/intl/msg_hash_de.h index 1e1867c016..18e166a442 100644 --- a/intl/msg_hash_de.h +++ b/intl/msg_hash_de.h @@ -3622,3 +3622,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_el.h b/intl/msg_hash_el.h index 7cd7f05e22..5b7887e625 100644 --- a/intl/msg_hash_el.h +++ b/intl/msg_hash_el.h @@ -7714,3 +7714,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_eo.h b/intl/msg_hash_eo.h index 4786ee10ee..7e16db1fb3 100644 --- a/intl/msg_hash_eo.h +++ b/intl/msg_hash_eo.h @@ -3361,3 +3361,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_es.h b/intl/msg_hash_es.h index b693e7a0ba..f6f66eda2f 100644 --- a/intl/msg_hash_es.h +++ b/intl/msg_hash_es.h @@ -7651,3 +7651,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_fr.h b/intl/msg_hash_fr.h index 8fd36db65f..9952253f46 100644 --- a/intl/msg_hash_fr.h +++ b/intl/msg_hash_fr.h @@ -3520,3 +3520,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_it.h b/intl/msg_hash_it.h index 4faa7279cd..1c5565120d 100644 --- a/intl/msg_hash_it.h +++ b/intl/msg_hash_it.h @@ -3580,3 +3580,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_ja.h b/intl/msg_hash_ja.h index 647be353cb..97e0f447dc 100644 --- a/intl/msg_hash_ja.h +++ b/intl/msg_hash_ja.h @@ -4029,3 +4029,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_ko.h b/intl/msg_hash_ko.h index 5cdf33a748..83522cd4a0 100644 --- a/intl/msg_hash_ko.h +++ b/intl/msg_hash_ko.h @@ -3481,3 +3481,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_lbl.h b/intl/msg_hash_lbl.h index 112fb8d7de..df82b2f9ad 100644 --- a/intl/msg_hash_lbl.h +++ b/intl/msg_hash_lbl.h @@ -1729,3 +1729,7 @@ MSG_HASH(MENU_ENUM_LABEL_MENU_USE_PREFERRED_SYSTEM_COLOR_THEME, "menu_use_preferred_system_color_theme") MSG_HASH(MENU_ENUM_LABEL_NO_MUSIC_AVAILABLE, "no_music") +MSG_HASH(MENU_ENUM_LABEL_NO_VIDEOS_AVAILABLE, + "no_videos") +MSG_HASH(MENU_ENUM_LABEL_NO_IMAGES_AVAILABLE, + "no_images") diff --git a/intl/msg_hash_nl.h b/intl/msg_hash_nl.h index ccab66062c..ea7fad42a8 100644 --- a/intl/msg_hash_nl.h +++ b/intl/msg_hash_nl.h @@ -3367,3 +3367,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "Geen muziek beschikbaar." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "Geen videos beschikbaar." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "Geen afbeeldingen beschikbaar." + ) diff --git a/intl/msg_hash_pl.h b/intl/msg_hash_pl.h index d2a4754630..daeaaa9497 100644 --- a/intl/msg_hash_pl.h +++ b/intl/msg_hash_pl.h @@ -3783,3 +3783,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_pt_br.h b/intl/msg_hash_pt_br.h index cff4dcaab4..da7cdcbe76 100644 --- a/intl/msg_hash_pt_br.h +++ b/intl/msg_hash_pt_br.h @@ -7745,3 +7745,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_pt_pt.h b/intl/msg_hash_pt_pt.h index 2efb0779ac..7cf963bce5 100644 --- a/intl/msg_hash_pt_pt.h +++ b/intl/msg_hash_pt_pt.h @@ -3447,3 +3447,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_ru.h b/intl/msg_hash_ru.h index fc7c4af09d..ae0e5c8a5a 100644 --- a/intl/msg_hash_ru.h +++ b/intl/msg_hash_ru.h @@ -3650,3 +3650,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_us.h b/intl/msg_hash_us.h index 8136eaeb52..fa2539944b 100644 --- a/intl/msg_hash_us.h +++ b/intl/msg_hash_us.h @@ -7745,3 +7745,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/intl/msg_hash_vn.h b/intl/msg_hash_vn.h index f518f45856..5301a35d17 100644 --- a/intl/msg_hash_vn.h +++ b/intl/msg_hash_vn.h @@ -3520,3 +3520,11 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, "No music available." ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, + "No videos available." + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, + "No images available." + ) diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index 47062cf43c..3e28a9cb04 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -4784,6 +4784,7 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist } break; case DISPLAYLIST_VIDEO_HISTORY: + info->count = 0; #if defined(HAVE_FFMPEG) || defined(HAVE_MPV) { settings_t *settings = config_get_ptr(); @@ -4800,13 +4801,15 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist } #endif - if (count == 0) + if (info->count == 0) { menu_entries_append_enum(info->list, - msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NO_HISTORY_AVAILABLE), - msg_hash_to_str(MENU_ENUM_LABEL_NO_HISTORY_AVAILABLE), - MENU_ENUM_LABEL_NO_HISTORY_AVAILABLE, + msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE), + msg_hash_to_str(MENU_ENUM_LABEL_NO_VIDEOS_AVAILABLE), + MENU_ENUM_LABEL_NO_VIDEOS_AVAILABLE, MENU_INFO_MESSAGE, 0, 0); + info->need_push_no_playlist_entries = false; + ret = 0; } if (ret == 0) @@ -7815,6 +7818,7 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist } break; case DISPLAYLIST_IMAGES_HISTORY: + info->count = 0; #ifdef HAVE_IMAGEVIEWER { settings_t *settings = config_get_ptr(); @@ -7828,13 +7832,15 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist } } #endif - if (count == 0) + if (info->count == 0) { menu_entries_append_enum(info->list, - msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NO_HISTORY_AVAILABLE), - msg_hash_to_str(MENU_ENUM_LABEL_NO_HISTORY_AVAILABLE), - MENU_ENUM_LABEL_NO_HISTORY_AVAILABLE, + msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE), + msg_hash_to_str(MENU_ENUM_LABEL_NO_IMAGES_AVAILABLE), + MENU_ENUM_LABEL_NO_IMAGES_AVAILABLE, MENU_INFO_MESSAGE, 0, 0); + info->need_push_no_playlist_entries = false; + ret = 0; } ret = 0; diff --git a/msg_hash.h b/msg_hash.h index fe45813f5d..2066217740 100644 --- a/msg_hash.h +++ b/msg_hash.h @@ -439,6 +439,8 @@ enum msg_hash_enums MENU_LABEL(NO_HISTORY_AVAILABLE), MENU_LABEL(NO_MUSIC_AVAILABLE), + MENU_LABEL(NO_VIDEOS_AVAILABLE), + MENU_LABEL(NO_IMAGES_AVAILABLE), MENU_ENUM_LABEL_DISCORD_IN_MENU, MENU_ENUM_LABEL_VALUE_DISCORD_IN_MENU,