Add some missing override labels.
[dcpomatic.git] / src / tools / dcpomatic_kdm.cc
index df55318e6cc178a8fce2e125bb9ec1946340c512..481b0fb8b0130d936fc1c2aeb20400296e48a0a8 100644 (file)
@@ -22,7 +22,6 @@
 #include "wx/about_dialog.h"
 #include "wx/dcpomatic_button.h"
 #include "wx/editable_list.h"
-#include "wx/file_dialog_wrapper.h"
 #include "wx/file_picker_ctrl.h"
 #include "wx/full_config_dialog.h"
 #include "wx/job_view_dialog.h"
 #include <dcp/exceptions.h>
 #include "lib/warnings.h"
 DCPOMATIC_DISABLE_WARNINGS
-#include <wx/wx.h>
+#include <wx/filepicker.h>
 #include <wx/preferences.h>
 #include <wx/splash.h>
-#include <wx/filepicker.h>
+#include <wx/treectrl.h>
+#include <wx/wx.h>
 DCPOMATIC_ENABLE_WARNINGS
 #ifdef __WXOSX__
 #include <ApplicationServices/ApplicationServices.h>
@@ -180,8 +180,7 @@ public:
                h = new StaticText (overall_panel, _("Output"));
                h->SetFont (subheading_font);
                right->Add (h, 0, wxTOP, DCPOMATIC_SIZER_Y_GAP * 2);
-               /* XXX: hard-coded non-interop here */
-               _output = new KDMOutputPanel (overall_panel, false);
+               _output = new KDMOutputPanel (overall_panel);
                right->Add (_output, 0, wxALL, DCPOMATIC_SIZER_Y_GAP);
 
                _create = new Button (overall_panel, _("Create KDMs"));
@@ -339,7 +338,7 @@ private:
                                                begin,
                                                end,
                                                decrypted.annotation_text().get_value_or (""),
-                                               decrypted.content_title_text(),
+                                               title,
                                                dcp::LocalTime().as_string()
                                                );
 
@@ -407,9 +406,9 @@ private:
                _output->setup_sensitivity ();
                wxArrayTreeItemIds sel;
                _dkdm->GetSelections (sel);
-               _create->Enable (!_screens->screens().empty() && sel.GetCount() > 0);
                auto group = dynamic_pointer_cast<DKDMGroup>(selected_dkdm());
                auto dkdm = dynamic_pointer_cast<DKDM>(selected_dkdm());
+               _create->Enable (!_screens->screens().empty() && sel.GetCount() > 0 && dkdm);
                _remove_dkdm->Enable (sel.GetCount() > 0 && (!group || group->name() != "root"));
                _export_dkdm->Enable (sel.GetCount() > 0 && dkdm);
        }
@@ -621,7 +620,7 @@ public:
 
 private:
 
-       bool OnInit ()
+       bool OnInit () override
        {
                wxSplashScreen* splash = nullptr;
 
@@ -720,7 +719,7 @@ private:
                return false;
        }
 
-       void OnUnhandledException ()
+       void OnUnhandledException () override
        {
                error_dialog (nullptr, _("An unknown exception occurred.") + "  " + REPORT_PROBLEM);
        }