projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Patch from Aaron Boxer adding initial support for GPU-powered J2K encoding via his...
[dcpomatic.git]
/
src
/
wx
/
controls.h
diff --git
a/src/wx/controls.h
b/src/wx/controls.h
index d70eb9432ba024b0e359638e203b57393b81d056..75bae9bb3877635f50e02f27aa67fdb48baca83f 100644
(file)
--- a/
src/wx/controls.h
+++ b/
src/wx/controls.h
@@
-1,5
+1,5
@@
/*
/*
- Copyright (C) 2018 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2018
-2021
Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
This file is part of DCP-o-matic.
@@
-18,45
+18,60
@@
*/
*/
+
#ifndef DCPOMATIC_CONTROLS_H
#define DCPOMATIC_CONTROLS_H
#ifndef DCPOMATIC_CONTROLS_H
#define DCPOMATIC_CONTROLS_H
+
+#include "lib/change_signaller.h"
#include "lib/dcpomatic_time.h"
#include "lib/dcpomatic_time.h"
-#include "lib/
types
.h"
-#include
"lib/film.h"
-#include "lib/spl.h"
+#include "lib/
film_property
.h"
+#include
<dcp/warnings.h>
+LIBDCP_DISABLE_WARNINGS
#include <wx/wx.h>
#include <wx/wx.h>
-#include <boost/shared_ptr.hpp>
+LIBDCP_ENABLE_WARNINGS
#include <boost/signals2.hpp>
#include <boost/signals2.hpp>
-class FilmViewer;
-class
Film
;
+
+class
CheckBox
;
class ClosedCaptionsDialog;
class Content;
class ClosedCaptionsDialog;
class Content;
+class ContentView;
+class Film;
+class FilmViewer;
+class MarkersPanel;
class PlayerVideo;
class PlayerVideo;
-class wxToggleButton;
+
class wxListCtrl;
class wxListCtrl;
-class ContentView;
+class wxToggleButton;
+
namespace dcp {
class CPL;
}
namespace dcp {
class CPL;
}
+
class Controls : public wxPanel
{
public:
Controls (
wxWindow* parent,
class Controls : public wxPanel
{
public:
Controls (
wxWindow* parent,
-
boost::shared_ptr<FilmViewer>
,
+
FilmViewer &
,
bool editor_controls = true
);
bool editor_controls = true
);
- virtual void set_film (boost::shared_ptr<Film> film);
- boost::shared_ptr<Film> film () const;
+ void set_film (std::shared_ptr<Film> film);
+
+ virtual void play () {};
+ virtual void stop () {};
+ void seek (int slider);
+
+ std::shared_ptr<Film> film () const;
void back_frame ();
void forward_frame ();
protected:
void back_frame ();
void forward_frame ();
protected:
+
virtual void started ();
virtual void stopped ();
virtual void setup_sensitivity ();
virtual void started ();
virtual void stopped ();
virtual void setup_sensitivity ();
@@
-64,9
+79,10
@@
protected:
wxSizer* _v_sizer;
wxBoxSizer* _button_sizer;
wxSizer* _v_sizer;
wxBoxSizer* _button_sizer;
- boost::shared_ptr<Film> _film;
+ std::shared_ptr<Film> _film;
+ MarkersPanel* _markers;
wxSlider* _slider;
wxSlider* _slider;
-
boost::shared_ptr<FilmViewer>
_viewer;
+
FilmViewer&
_viewer;
boost::optional<std::string> _active_job;
private:
boost::optional<std::string> _active_job;
private:
@@
-82,20
+98,20
@@
private:
void jump_to_selected_clicked ();
void timecode_clicked ();
void active_jobs_changed (boost::optional<std::string>);
void jump_to_selected_clicked ();
void timecode_clicked ();
void active_jobs_changed (boost::optional<std::string>);
- DCPTime nudge_amount (wxKeyboardState& ev);
- void image_changed (
boost
::weak_ptr<PlayerVideo>);
+
dcpomatic::
DCPTime nudge_amount (wxKeyboardState& ev);
+ void image_changed (
std
::weak_ptr<PlayerVideo>);
void outline_content_changed ();
void eye_changed ();
void outline_content_changed ();
void eye_changed ();
- void position_changed ();
+ void update_position ();
+ void film_change(ChangeType, FilmProperty);
- typedef std::pair<
boost
::shared_ptr<dcp::CPL>, boost::filesystem::path> CPL;
+ typedef std::pair<
std
::shared_ptr<dcp::CPL>, boost::filesystem::path> CPL;
- bool _slider_being_moved;
- bool _was_running_before_slider;
+ bool _slider_being_moved = false;
-
wxCheckBox* _outline_content
;
- wxChoice* _eye;
-
wxCheckBox* _jump_to_selected
;
+
CheckBox* _outline_content = nullptr
;
+ wxChoice* _eye
= nullptr
;
+
CheckBox* _jump_to_selected = nullptr
;
wxButton* _rewind_button;
wxButton* _back_button;
wxButton* _forward_button;
wxButton* _rewind_button;
wxButton* _back_button;
wxButton* _forward_button;
@@
-104,7
+120,11
@@
private:
ClosedCaptionsDialog* _closed_captions_dialog;
ClosedCaptionsDialog* _closed_captions_dialog;
+ wxTimer _timer;
+
+ boost::signals2::scoped_connection _film_change_connection;
boost::signals2::scoped_connection _config_changed_connection;
};
boost::signals2::scoped_connection _config_changed_connection;
};
+
#endif
#endif