X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Fwx%2Ffilm_viewer.cc;h=a46983a6f9972b0bf41efbc28ef1a4d03372988e;hb=cb990adba9c57e5107ef2aa9716cf0a26c1df83d;hp=2416c6776841690fee63786d52b20725a578d8fd;hpb=04eebe07e2f64bd15f6887a10ab51fb92c52901a;p=dcpomatic.git diff --git a/src/wx/film_viewer.cc b/src/wx/film_viewer.cc index 2416c6776..a46983a6f 100644 --- a/src/wx/film_viewer.cc +++ b/src/wx/film_viewer.cc @@ -55,7 +55,7 @@ using boost::dynamic_pointer_cast; using boost::weak_ptr; using dcp::Size; -FilmViewer::FilmViewer (shared_ptr f, wxWindow* p) +FilmViewer::FilmViewer (wxWindow* p) : wxPanel (p) , _panel (new wxPanel (this)) , _outline_content (new wxCheckBox (this, wxID_ANY, _("Outline content"))) @@ -109,8 +109,8 @@ FilmViewer::FilmViewer (shared_ptr f, wxWindow* p) _back_button->Bind (wxEVT_COMMAND_BUTTON_CLICKED, boost::bind (&FilmViewer::back_clicked, this)); _forward_button->Bind (wxEVT_COMMAND_BUTTON_CLICKED, boost::bind (&FilmViewer::forward_clicked, this)); - set_film (f); - + set_film (shared_ptr ()); + JobManager::instance()->ActiveJobsChanged.connect ( bind (&FilmViewer::active_jobs_changed, this, _1) ); @@ -151,6 +151,8 @@ FilmViewer::set_film (shared_ptr f) calculate_sizes (); get (_position, _last_get_accurate); + + setup_sensitivity (); } void @@ -170,7 +172,7 @@ FilmViewer::get (DCPTime p, bool accurate) list > pvf = _player->get_video (p, accurate); if (!pvf.empty ()) { try { - _frame = pvf.front()->image (true); + _frame = pvf.front()->image (PIX_FMT_RGB24, true); _frame = _frame->scale (_frame->size(), Scaler::from_id ("fastbilinear"), PIX_FMT_RGB24, false); _position = pvf.front()->time (); _inter_position = pvf.front()->inter_position ();