- wxBoxSizer* vertical = new wxBoxSizer (wxVERTICAL);
-
- add_label_to_sizer (vertical, this, "Make KDMs for");
-
- wxBoxSizer* targets = new wxBoxSizer (wxHORIZONTAL);
-
- _targets = new wxTreeCtrl (this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTR_HIDE_ROOT | wxTR_MULTIPLE | wxTR_HAS_BUTTONS);
- targets->Add (_targets, 1, wxEXPAND | wxALL, 6);
-
- _root = _targets->AddRoot ("Foo");
- shared_ptr<Cinema> csy (new Cinema ("City Screen York"));
- add_cinema (csy);
- add_screen (csy, shared_ptr<Screen> (new Screen ("Screen 1")));
- add_screen (csy, shared_ptr<Screen> (new Screen ("Screen 2")));
- add_screen (csy, shared_ptr<Screen> (new Screen ("Screen 3")));
- _targets->ExpandAll ();
-
- wxBoxSizer* target_buttons = new wxBoxSizer (wxVERTICAL);
-
- _new_cinema = new wxButton (this, wxID_ANY, _("New Cinema..."));
- target_buttons->Add (_new_cinema, 1, wxEXPAND | wxALL, 6);
- _new_screen = new wxButton (this, wxID_ANY, _("New Screen..."));
- target_buttons->Add (_new_screen, 1, wxEXPAND | wxALL, 6);
-
- targets->Add (target_buttons, 0, wxEXPAND | wxALL, 6);
-
- vertical->Add (targets, 0, wxEXPAND | wxALL, 6);
-
- wxFlexGridSizer* table = new wxFlexGridSizer (3, 2, 6);
- add_label_to_sizer (table, this, "From");
- _from_date = new wxDatePickerCtrl (this, wxID_ANY);
- table->Add (_from_date, 1, wxEXPAND);
- _from_time = new wxTimePickerCtrl (this, wxID_ANY);
- table->Add (_from_time, 1, wxEXPAND);
-
- add_label_to_sizer (table, this, "To");
- _to_date = new wxDatePickerCtrl (this, wxID_ANY);
- table->Add (_to_date, 1, wxEXPAND);
- _to_time = new wxTimePickerCtrl (this, wxID_ANY);
- table->Add (_to_time, 1, wxEXPAND);
-
- add_label_to_sizer (table, this, "Write to");
-
-#ifdef __WXMSW__
- _folder = new DirPickerCtrl (this);
-#else
- _folder = new wxDirPickerCtrl (this, wxDD_DIR_MUST_EXIST);
-#endif
-
- table->Add (_folder, 1, wxEXPAND);
-
- vertical->Add (table, 1, wxEXPAND | wxALL, 6);
-
- wxSizer* buttons = CreateSeparatedButtonSizer (wxOK);
- if (buttons) {
- vertical->Add (buttons, wxSizerFlags().Expand().DoubleBorder());
+ /* Main sizers */
+ wxBoxSizer* horizontal = new wxBoxSizer (wxHORIZONTAL);
+ wxBoxSizer* left = new wxBoxSizer (wxVERTICAL);
+ wxBoxSizer* right = new wxBoxSizer (wxVERTICAL);
+
+ horizontal->Add (left, 1, wxEXPAND | wxRIGHT, DCPOMATIC_SIZER_X_GAP * 4);
+ horizontal->Add (right, 1, wxEXPAND);
+
+ /* Font for sub-headings */
+ wxFont subheading_font (*wxNORMAL_FONT);
+ subheading_font.SetWeight (wxFONTWEIGHT_BOLD);
+
+ /* Sub-heading: Screens */
+ wxStaticText* h = new StaticText (this, _("Screens"));
+ h->SetFont (subheading_font);
+ left->Add (h, 0, wxALIGN_CENTER_VERTICAL | wxBOTTOM, DCPOMATIC_SIZER_Y_GAP);
+ _screens = new ScreensPanel (this);
+ left->Add (_screens, 1, wxEXPAND | wxBOTTOM, DCPOMATIC_SIZER_Y_GAP);
+
+ /* Sub-heading: Timing */
+ /// TRANSLATORS: translate the word "Timing" here; do not include the "KDM|" prefix
+ h = new StaticText (this, S_("KDM|Timing"));
+ h->SetFont (subheading_font);
+ right->Add (h, 0, wxALIGN_CENTER_VERTICAL, DCPOMATIC_SIZER_Y_GAP * 2);
+ _timing = new KDMTimingPanel (this);
+ right->Add (_timing);
+
+ /* Sub-heading: CPL */
+ h = new StaticText (this, _("CPL"));
+ h->SetFont (subheading_font);
+ right->Add (h, 0, wxALIGN_CENTER_VERTICAL, DCPOMATIC_SIZER_Y_GAP * 2);
+
+ vector<CPLSummary> cpls;
+ BOOST_FOREACH (CPLSummary const & i, film->cpls()) {
+ if (i.encrypted) {
+ cpls.push_back (i);
+ }