+
+
+void
+Hints::check_text_languages ()
+{
+ for (auto i: film()->content()) {
+ for (auto j: i->text) {
+ if (j->use() && !j->language()) {
+ hint (_("At least one piece of subtitle or closed caption content has no specified language. "
+ "It is advisable to set the language for each piece of subtitle or closed caption content "
+ "in the \"Content→Timed text\", \"Content→Open subtitles\" or \"Content→Closed captions\" tab."));
+ return;
+ }
+ }
+ }
+}
+
+
+void
+Hints::check_audio_language ()
+{
+ auto content = film()->content();
+ auto mapped_audio =
+ std::find_if(content.begin(), content.end(), [](shared_ptr<const Content> c) {
+ return c->audio && !c->audio->mapping().mapped_output_channels().empty();
+ });
+
+ if (mapped_audio != content.end() && !film()->audio_language()) {
+ hint (_("Some of your content has audio but you have not set the audio language. It is advisable to set the audio language "
+ "in the \"DCP\" tab unless your audio has no spoken parts."));
+ }
+}
+