From d75c187c5b68a3a38c67ab5e469d9e5ba91f9a01 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 27 Nov 2017 07:04:52 +0100 Subject: [PATCH] Don't show 'Scanning of Directory Finished' if we are scanning a file instead --- intl/msg_hash_chs.h | 2 ++ intl/msg_hash_cht.h | 2 ++ intl/msg_hash_de.h | 2 ++ intl/msg_hash_eo.h | 2 ++ intl/msg_hash_fr.h | 2 ++ intl/msg_hash_it.h | 2 ++ intl/msg_hash_ja.h | 2 ++ intl/msg_hash_ko.h | 2 ++ intl/msg_hash_nl.h | 2 ++ intl/msg_hash_pt_br.h | 2 ++ intl/msg_hash_pt_pt.h | 2 ++ intl/msg_hash_ru.h | 2 ++ intl/msg_hash_us.h | 2 ++ intl/msg_hash_vn.h | 2 ++ msg_hash.h | 1 + tasks/task_database.c | 11 ++++++++--- 16 files changed, 37 insertions(+), 3 deletions(-) diff --git a/intl/msg_hash_chs.h b/intl/msg_hash_chs.h index 63aa35cfb5..14bb988f19 100644 --- a/intl/msg_hash_chs.h +++ b/intl/msg_hash_chs.h @@ -3205,3 +3205,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_cht.h b/intl/msg_hash_cht.h index a5be0c3d3a..5a70c2d652 100644 --- a/intl/msg_hash_cht.h +++ b/intl/msg_hash_cht.h @@ -3205,3 +3205,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_de.h b/intl/msg_hash_de.h index 9e03d9f147..26ac4331ac 100644 --- a/intl/msg_hash_de.h +++ b/intl/msg_hash_de.h @@ -3315,3 +3315,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_eo.h b/intl/msg_hash_eo.h index 133ef8253d..d5d1d0258b 100644 --- a/intl/msg_hash_eo.h +++ b/intl/msg_hash_eo.h @@ -3068,3 +3068,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_fr.h b/intl/msg_hash_fr.h index d27634fae8..7fe0883274 100644 --- a/intl/msg_hash_fr.h +++ b/intl/msg_hash_fr.h @@ -3237,3 +3237,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_it.h b/intl/msg_hash_it.h index b403f7bffd..dfa0290a1e 100644 --- a/intl/msg_hash_it.h +++ b/intl/msg_hash_it.h @@ -3295,3 +3295,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_ja.h b/intl/msg_hash_ja.h index 6ccf4feb78..7d502db12d 100644 --- a/intl/msg_hash_ja.h +++ b/intl/msg_hash_ja.h @@ -3247,3 +3247,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_ko.h b/intl/msg_hash_ko.h index 86d3798887..8b6daaccfd 100644 --- a/intl/msg_hash_ko.h +++ b/intl/msg_hash_ko.h @@ -3200,3 +3200,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_nl.h b/intl/msg_hash_nl.h index 6040e5470e..f912f35260 100644 --- a/intl/msg_hash_nl.h +++ b/intl/msg_hash_nl.h @@ -3068,3 +3068,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_pt_br.h b/intl/msg_hash_pt_br.h index 21b574287b..376860a968 100644 --- a/intl/msg_hash_pt_br.h +++ b/intl/msg_hash_pt_br.h @@ -4185,3 +4185,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_pt_pt.h b/intl/msg_hash_pt_pt.h index 757e1d4058..b48e9717cd 100644 --- a/intl/msg_hash_pt_pt.h +++ b/intl/msg_hash_pt_pt.h @@ -3175,3 +3175,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_ru.h b/intl/msg_hash_ru.h index 5e11949ec3..25d792c7eb 100644 --- a/intl/msg_hash_ru.h +++ b/intl/msg_hash_ru.h @@ -3258,3 +3258,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_us.h b/intl/msg_hash_us.h index c3ec369eb3..5fb03ee34b 100644 --- a/intl/msg_hash_us.h +++ b/intl/msg_hash_us.h @@ -3337,3 +3337,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/intl/msg_hash_vn.h b/intl/msg_hash_vn.h index 41a38b6e28..8be07e4d75 100644 --- a/intl/msg_hash_vn.h +++ b/intl/msg_hash_vn.h @@ -3229,3 +3229,5 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically add content to playlist") MSG_HASH(MENU_ENUM_SUBLABEL_AUTOMATICALLY_ADD_CONTENT_TO_PLAYLIST, "Automatically scans loaded content so they appear inside playlists.") +MSG_HASH(MSG_SCANNING_OF_FILE_FINISHED, + "Scanning of file finished") diff --git a/msg_hash.h b/msg_hash.h index daffdcfc92..fdd00470e1 100644 --- a/msg_hash.h +++ b/msg_hash.h @@ -357,6 +357,7 @@ enum msg_hash_enums MSG_PREPARING_FOR_CONTENT_SCAN, MSG_SCANNING, MSG_SCANNING_OF_DIRECTORY_FINISHED, + MSG_SCANNING_OF_FILE_FINISHED, MSG_LOADED_STATE_FROM_SLOT, MSG_LOADED_STATE_FROM_SLOT_AUTO, MSG_REMOVING_TEMPORARY_CONTENT_FILE, diff --git a/tasks/task_database.c b/tasks/task_database.c index ddb079077d..afe42dd83e 100644 --- a/tasks/task_database.c +++ b/tasks/task_database.c @@ -1254,9 +1254,14 @@ static void task_database_handler(retro_task_t *task) } else { - runloop_msg_queue_push( - msg_hash_to_str(MSG_SCANNING_OF_DIRECTORY_FINISHED), - 0, 180, true); + if (db->is_directory) + runloop_msg_queue_push( + msg_hash_to_str(MSG_SCANNING_OF_DIRECTORY_FINISHED), + 0, 180, true); + else + runloop_msg_queue_push( + msg_hash_to_str(MSG_SCANNING_OF_FILE_FINISHED), + 0, 180, true); goto task_finished; } break;