Use sqlite for cinema and DKDM recipient lists.
[dcpomatic.git] / src / wx / content_panel.cc
index 8a98bc1a43d706ee78336f1c61a8171ec9629d7f..07a632b4ad387e121f0f2e7152a91a26b47d54b0 100644 (file)
 
 #include "audio_panel.h"
 #include "content_panel.h"
+#include "content_timeline_dialog.h"
 #include "dcpomatic_button.h"
 #include "dir_dialog.h"
 #include "file_dialog.h"
 #include "film_viewer.h"
 #include "image_sequence_dialog.h"
 #include "text_panel.h"
-#include "timeline_dialog.h"
 #include "timing_panel.h"
 #include "video_panel.h"
 #include "wx_util.h"
+#include "wx_variant.h"
 #include "lib/audio_content.h"
 #include "lib/case_insensitive_sorter.h"
 #include "lib/compose.hpp"
 #include "lib/image_content.h"
 #include "lib/log.h"
 #include "lib/playlist.h"
-#include "lib/scope_guard.h"
 #include "lib/string_text_file.h"
 #include "lib/string_text_file_content.h"
 #include "lib/text_content.h"
 #include "lib/video_content.h"
 #include <dcp/filesystem.h>
+#include <dcp/scope_guard.h>
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/display.h>
@@ -602,6 +603,7 @@ ContentPanel::add_file_clicked ()
                wxT("All files|*.*|Subtitle files|*.srt;*.xml|Audio files|*.wav;*.w64;*.flac;*.aif;*.aiff"),
                wxFD_MULTIPLE | wxFD_CHANGE_DIR,
                "AddFilesPath",
+               {},
                add_files_override_path(_film)
                );
 
@@ -672,10 +674,14 @@ ContentPanel::add_dcp(boost::filesystem::path dcp)
        } catch (ProjectFolderError &) {
                error_dialog (
                        _parent,
-                       _(
-                               "This looks like a DCP-o-matic project folder, which cannot be added to a different project.  "
-                               "Choose the DCP folder inside the DCP-o-matic project folder if that's what you want to import."
-                        )
+                       wxString::Format(
+                               _(
+                                       "This looks like a %s project folder, which cannot be added to a different project.  "
+                                       "Choose the DCP folder inside the %s project folder if that's what you want to import."
+                                ),
+                               variant::wx::dcpomatic(),
+                               variant::wx::dcpomatic()
+                               )
                        );
        } catch (exception& e) {
                error_dialog(_parent, e.what());
@@ -820,7 +826,7 @@ ContentPanel::set_selection (ContentList cl)
 {
        {
                _no_check_selection = true;
-               ScopeGuard sg = [this]() { _no_check_selection = false; };
+               dcp::ScopeGuard sg = [this]() { _no_check_selection = false; };
 
                auto content = _film->content ();
                for (size_t i = 0; i < content.size(); ++i) {