/*
- Copyright (C) 2014-2016 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2014-2018 Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
*/
-#include "lib/content_subtitle.h"
+#include "lib/content_caption.h"
#include <boost/shared_ptr.hpp>
#include <wx/wx.h>
#include <wx/listctrl.h>
class Decoder;
+class FilmViewer;
class SubtitleView : public wxDialog
{
public:
- SubtitleView (wxWindow *, boost::shared_ptr<Film>, boost::shared_ptr<Decoder>, DCPTime position);
+ SubtitleView (wxWindow *, boost::shared_ptr<Film>, boost::shared_ptr<Content> content, boost::shared_ptr<Decoder>, FilmViewer* viewer);
private:
- void data (ContentTextSubtitle cts);
+ void data_start (ContentTextCaption cts);
+ void data_stop (ContentTime time);
+ void subtitle_selected (wxListEvent &);
wxListCtrl* _list;
int _subs;
boost::optional<FrameRateChange> _frc;
+ boost::optional<int> _last_count;
+ std::vector<ContentTime> _start_times;
+ boost::weak_ptr<Content> _content;
+ FilmViewer* _film_viewer;
};