Add a load of explicit keywords.
[dcpomatic.git] / src / tools / dcpomatic_batch.cc
index 7a4f506224716a28219b67c30307a70c0c519e04..f6197b1e22f7bc473cfb9fc2622c1f7e11383d66 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013-2015 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2018 Carl Hetherington <cth@carlh.net>
 
     This file is part of DCP-o-matic.
 
@@ -91,7 +91,7 @@ setup_menu (wxMenuBar* m)
 class DOMFrame : public wxFrame
 {
 public:
-       DOMFrame (wxString const & title)
+       explicit DOMFrame (wxString const & title)
                : wxFrame (NULL, -1, title)
                , _sizer (new wxBoxSizer (wxVERTICAL))
                , _config_dialog (0)
@@ -137,7 +137,7 @@ public:
                } catch (std::exception& e) {
                        wxString p = std_to_wx (path.string ());
                        wxCharBuffer b = p.ToUTF8 ();
-                       error_dialog (this, wxString::Format (_("Could not open film at %s (%s)"), p.data(), std_to_wx (e.what()).data()));
+                       error_dialog (this, wxString::Format (_("Could not open film at %s"), p.data()), std_to_wx(e.what()));
                }
        }
 
@@ -252,7 +252,7 @@ static const wxCmdLineEntryDesc command_line_description[] = {
 class JobServer : public Server
 {
 public:
-       JobServer (DOMFrame* frame)
+       explicit JobServer (DOMFrame* frame)
                : Server (BATCH_JOB_PORT)
                , _frame (frame)
        {}
@@ -280,6 +280,7 @@ class App : public wxApp
        bool OnInit ()
        {
                SetAppName (_("DCP-o-matic Batch Converter"));
+               is_batch_converter = true;
 
                Config::FailedToLoad.connect (boost::bind (&App::config_failed_to_load, this));
                Config::Warning.connect (boost::bind (&App::config_warning, this, _1));
@@ -337,12 +338,9 @@ class App : public wxApp
                                        film->make_dcp ();
                                } catch (exception& e) {
                                        error_dialog (
-                                               0, std_to_wx (
-                                                       String::compose (
-                                                               wx_to_std (_("Could not load film %1 (%2)")), i.string(),
-                                                               e.what()
-                                                               )
-                                                       )
+                                               0,
+                                               std_to_wx (String::compose (wx_to_std (_("Could not load film %1")), i.string())),
+                                               std_to_wx(e.what())
                                                );
                                }
                        }