/* Copyright (C) 2012-2020 Carl Hetherington This file is part of DCP-o-matic. DCP-o-matic is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. DCP-o-matic is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with DCP-o-matic. If not, see . */ #include "content_sub_panel.h" #include "timecode.h" #include "suspender.h" class FilmViewer; class TimingPanel : public ContentSubPanel { public: TimingPanel(ContentPanel *, FilmViewer& viewer); void create() override; void film_changed(FilmProperty) override; void film_content_changed(int) override; void content_selection_changed() override; private: void position_changed(); void move_to_start_of_reel_clicked(); void full_length_changed(); void trim_start_changed(); void trim_start_to_playhead_clicked(); void trim_end_changed(); void trim_end_to_playhead_clicked(); void play_length_changed(); void update_full_length(); void update_play_length(); void setup_sensitivity(); void add_to_grid() override; FilmViewer& _viewer; std::vector _label; wxStaticText* _colon[3]; wxStaticText* _position_label; Timecode* _position; wxButton* _move_to_start_of_reel; wxStaticText* _full_length_label; Timecode* _full_length; wxStaticText* _trim_start_label; Timecode* _trim_start; wxButton* _trim_start_to_playhead; wxButton* _trim_end_to_playhead; wxStaticText* _trim_end_label; Timecode* _trim_end; wxStaticText* _play_length_label; Timecode* _play_length; Suspender _film_content_changed_suspender; };