+ wxDirDialog* d = new wxDirDialog (_panel, _("Choose a DCP folder"), wxT (""), wxDD_DIR_MUST_EXIST);
+ int r = d->ShowModal ();
+ boost::filesystem::path const path (wx_to_std (d->GetPath ()));
+ d->Destroy ();
+
+ if (r != wxID_OK) {
+ return;
+ }
+
+ try {
+ _film->examine_and_add_content (shared_ptr<Content> (new DCPContent (_film, path)));
+ } catch (exception& e) {
+ error_dialog (_parent, e.what());
+ }
+}
+
+/** @return true if this remove "click" should be ignored */
+bool
+ContentPanel::remove_clicked (bool hotkey)
+{
+ /* If the method was called because Delete was pressed check that our notebook page
+ is visible and that the content list is focussed.
+ */
+ if (hotkey && (_parent->GetCurrentPage() != _panel || !_content->HasFocus())) {
+ return true;
+ }
+
+ BOOST_FOREACH (shared_ptr<Content> i, selected ()) {
+ _film->remove_content (i);