Remove redundant FilmViewer::video_position() and use FilmViewer::position() instead.
authorCarl Hetherington <cth@carlh.net>
Sun, 20 Oct 2019 20:20:06 +0000 (22:20 +0200)
committerCarl Hetherington <cth@carlh.net>
Wed, 8 Jan 2020 20:56:47 +0000 (21:56 +0100)
src/wx/film_viewer.h
src/wx/simple_video_view.cc

index d64eef4a9826d6eeb23702db65523153136126bf..d0041bd957e6394d62acdc1b79f995a7b43006a9 100644 (file)
@@ -135,9 +135,6 @@ public:
        bool pad_black () const {
                return _pad_black;
        }
-       dcpomatic::DCPTime video_position () const {
-               return _video_position;
-       }
 
        boost::signals2::signal<void (boost::weak_ptr<PlayerVideo>)> ImageChanged;
        boost::signals2::signal<void ()> PositionChanged;
index 56e50ebed24ed20ccb014f2f8aa4c5eeecfeefcd..9aa73fe7ff35d0a7446a93b71e304cffab405f7d 100644 (file)
@@ -83,10 +83,10 @@ SimpleVideoView::paint ()
 
 #ifdef DCPOMATIC_VARIANT_SWAROOP
                DCPTime const period = DCPTime::from_seconds(Config::instance()->player_watermark_period() * 60);
-               int64_t n = _viewer->video_position().get() / period.get();
+               int64_t n = _viewer->position().get() / period.get();
                DCPTime from(n * period.get());
                DCPTime to = from + DCPTime::from_seconds(Config::instance()->player_watermark_duration() / 1000.0);
-               if (from <= _viewer->video_position() && _viewer->video_position() <= to) {
+               if (from <= _viewer->position() && _viewer->position() <= to) {
                        if (!_in_watermark) {
                                _in_watermark = true;
                                _watermark_x = rand() % panel_size.GetWidth();