- vertical->Add (h, 0, wxALIGN_CENTER_VERTICAL | wxTOP, DCPOMATIC_SIZER_Y_GAP * 2);
-
- /* CPL choice */
- wxBoxSizer* s = new wxBoxSizer (wxHORIZONTAL);
- add_label_to_sizer (s, this, _("CPL"), true);
- _cpl = new wxChoice (this, wxID_ANY);
- s->Add (_cpl, 1, wxEXPAND);
- _cpl_browse = new wxButton (this, wxID_ANY, _("Browse..."));
- s->Add (_cpl_browse, 0);
- vertical->Add (s, 0, wxEXPAND | wxTOP, DCPOMATIC_SIZER_GAP + 2);
-
- /* CPL details */
- wxFlexGridSizer* table = new wxFlexGridSizer (2, DCPOMATIC_SIZER_X_GAP, DCPOMATIC_SIZER_Y_GAP);
- add_label_to_sizer (table, this, _("DCP directory"), true);
- _dcp_directory = new wxStaticText (this, wxID_ANY, "");
- table->Add (_dcp_directory);
- add_label_to_sizer (table, this, _("CPL ID"), true);
- _cpl_id = new wxStaticText (this, wxID_ANY, "");
- table->Add (_cpl_id);
- add_label_to_sizer (table, this, _("CPL annotation text"), true);
- _cpl_annotation_text = new wxStaticText (this, wxID_ANY, "");
- table->Add (_cpl_annotation_text);
- vertical->Add (table, 0, wxEXPAND | wxTOP, DCPOMATIC_SIZER_GAP + 2);
-
- _cpls = film->cpls ();
- update_cpl_choice ();
+ 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);
+ }
+ }
+
+ _cpl = new KDMCPLPanel (this, cpls);
+ right->Add (_cpl, 0, wxEXPAND);