Note that newer libsub version is required.
[dcpomatic.git] / src / wx / standard_controls.cc
index 1e4ecc8d7fc74e5469c76759272110d209f42f1d..942c49fc4baf5b3d9fe1325c718efd8cd397d813 100644 (file)
 
 #include "film_viewer.h"
 #include "standard_controls.h"
+#include "lib/film.h"
+#include <dcp/warnings.h>
+LIBDCP_DISABLE_WARNINGS
 #include <wx/tglbtn.h>
 #include <wx/wx.h>
+LIBDCP_ENABLE_WARNINGS
 
 
 using std::shared_ptr;
 
 
-StandardControls::StandardControls (wxWindow* parent, shared_ptr<FilmViewer> viewer, bool editor_controls)
+StandardControls::StandardControls(wxWindow* parent, FilmViewer& viewer, bool editor_controls)
        : Controls (parent, viewer, editor_controls)
        , _play_button (new wxToggleButton(this, wxID_ANY, _("Play")))
 {
@@ -68,9 +72,9 @@ StandardControls::check_play_state ()
        }
 
        if (_play_button->GetValue()) {
-               _viewer->start ();
+               _viewer.start();
        } else {
-               _viewer->stop ();
+               _viewer.stop();
        }
 }