Cleanup: use new CheckBox::bind().
[dcpomatic.git] / src / wx / metadata_dialog.h
index 8483d861506d362194e20c2d89f1376ed99c7200..cda8d2acec2df2c2511f078cadc31f870edbb416 100644 (file)
 #define DCPOMATIC_METADATA_DIALOG_H
 
 
+#include "editable_list.h"
 #include "lib/change_signaller.h"
 #include "lib/film.h"
-#include "lib/warnings.h"
 #include "lib/weak_film.h"
-DCPOMATIC_DISABLE_WARNINGS
+#include <dcp/warnings.h>
+LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
-DCPOMATIC_ENABLE_WARNINGS
+LIBDCP_ENABLE_WARNINGS
+#include <unordered_map>
 
 
 class Button;
+class CheckBox;
+class Choice;
+class LanguageTagWidget;
+class RatingDialog;
+class wxSpinCtrlDouble;
 
 
 class MetadataDialog : public wxDialog, public WeakFilm
@@ -44,15 +51,33 @@ public:
 
 protected:
        virtual void setup_standard (wxPanel*, wxSizer*);
-       virtual void setup_advanced (wxPanel*, wxSizer*) {}
+       virtual void setup_advanced (wxPanel*, wxSizer*);
        virtual void film_changed (ChangeType type, Film::Property property);
        virtual void setup_sensitivity ();
 
+       EditableList<dcp::Rating, RatingDialog>* _ratings;
+       std::unordered_map<std::string, std::string> _rating_system_agency_to_name;
+
 private:
+       void sign_language_video_language_changed ();
        void edit_release_territory ();
        void enable_release_territory_changed ();
-
-       wxCheckBox* _enable_release_territory;
+       void facility_changed ();
+       void enable_facility_changed ();
+       void studio_changed ();
+       void enable_studio_changed ();
+       void temp_version_changed ();
+       void pre_release_changed ();
+       void red_band_changed ();
+       void two_d_version_of_three_d_changed ();
+       void chain_changed ();
+       void enable_chain_changed ();
+       void enable_luminance_changed ();
+       void luminance_changed ();
+       std::vector<dcp::Rating> ratings () const;
+       void set_ratings (std::vector<dcp::Rating> r);
+
+       CheckBox* _enable_release_territory;
        /** The current release territory displayed in the UI; since we can't easily convert
         *  the string in _release_territory_text to a RegionSubtag we just store the RegionSubtag
         *  alongside.
@@ -60,6 +85,20 @@ private:
        boost::optional<dcp::LanguageTag::RegionSubtag> _release_territory;
        wxStaticText* _release_territory_text;
        Button* _edit_release_territory;
+       LanguageTagWidget* _sign_language_video_language = nullptr;
+       CheckBox* _enable_facility;
+       wxTextCtrl* _facility;
+       CheckBox* _enable_chain;
+       wxTextCtrl* _chain;
+       CheckBox* _enable_studio;
+       wxTextCtrl* _studio;
+       CheckBox* _temp_version;
+       CheckBox* _pre_release;
+       CheckBox* _red_band;
+       CheckBox* _two_d_version_of_three_d;
+       CheckBox* _enable_luminance;
+       wxSpinCtrlDouble* _luminance_value;
+       Choice* _luminance_unit;
 
        boost::signals2::scoped_connection _film_changed_connection;
 };