summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/wx/gl_video_view.cc1
-rw-r--r--src/wx/gl_view.cc1
-rw-r--r--src/wx/gl_view.h6
3 files changed, 4 insertions, 4 deletions
diff --git a/src/wx/gl_video_view.cc b/src/wx/gl_video_view.cc
index c24736570..e53b63c51 100644
--- a/src/wx/gl_video_view.cc
+++ b/src/wx/gl_video_view.cc
@@ -81,7 +81,6 @@ GLVideoView::GLVideoView(FilmViewer* viewer, wxWindow *parent)
, GLView(parent)
, _rec2020(false)
{
- _canvas->Bind(wxEVT_PAINT, boost::bind(&GLVideoView::update, this));
_canvas->Bind(wxEVT_TIMER, boost::bind(&GLVideoView::check_for_butler_errors, this));
_timer.reset(new wxTimer(_canvas));
_timer->Start(2000);
diff --git a/src/wx/gl_view.cc b/src/wx/gl_view.cc
index 2c7424a29..ddae483f5 100644
--- a/src/wx/gl_view.cc
+++ b/src/wx/gl_view.cc
@@ -50,6 +50,7 @@ GLView::GLView(wxWindow* parent)
parent, attributes, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxFULL_REPAINT_ON_RESIZE
);
_canvas->Bind(wxEVT_SIZE, boost::bind(&GLView::size_changed, this, _1));
+ _canvas->Bind(wxEVT_PAINT, boost::bind(&GLView::update, this));
}
diff --git a/src/wx/gl_view.h b/src/wx/gl_view.h
index f20d5962a..2065f5ede 100644
--- a/src/wx/gl_view.h
+++ b/src/wx/gl_view.h
@@ -45,8 +45,6 @@ public:
GLView(wxWindow* parent);
virtual ~GLView();
- virtual void update();
-
wxWindow* canvas() const {
return _canvas;
}
@@ -56,12 +54,14 @@ public:
}
protected:
- virtual void size_changed(wxSizeEvent const& ev);
virtual void thread_setup() = 0;
virtual void draw() = 0;
virtual void thread_playing() = 0;
virtual boost::optional<int> time_until_next_frame() const = 0;
+ virtual void size_changed(wxSizeEvent const& ev);
+ virtual void update();
+
void start_thread_if_required();
void start();
void stop();