#include "film_editor.h"
#include "timeline.h"
#include "timeline_time_axis_view.h"
+#include "timeline_reels_view.h"
#include "timeline_video_content_view.h"
#include "timeline_audio_content_view.h"
#include "timeline_subtitle_content_view.h"
: wxPanel (parent, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxFULL_REPAINT_ON_RESIZE)
, _content_panel (cp)
, _film (film)
- , _time_axis_view (new TimelineTimeAxisView (*this, 32))
+ , _time_axis_view (new TimelineTimeAxisView (*this, 64))
+ , _reels_view (new TimelineReelsView (*this, 32))
, _tracks (0)
, _left_down (false)
, _down_view_position (0)
void
Timeline::film_changed (Film::Property p)
{
- if (p == Film::CONTENT) {
+ if (p == Film::CONTENT || p == Film::REEL_TYPE || p == Film::REEL_LENGTH) {
ensure_ui_thread ();
recreate_views ();
+ } else if (p == Film::CONTENT_ORDER) {
+ assign_tracks ();
+ if (!_left_down) {
+ /* Only do this if we are not dragging, as it's confusing otherwise */
+ setup_pixels_per_second ();
+ }
+ Refresh ();
}
}
_views.clear ();
_views.push_back (_time_axis_view);
+ _views.push_back (_reels_view);
BOOST_FOREACH (shared_ptr<Content> i, film->content ()) {
if (dynamic_pointer_cast<VideoContent> (i)) {
{
ensure_ui_thread ();
- if (property == ContentProperty::POSITION) {
- assign_tracks ();
- if (!_left_down) {
- /* Only do this if we are not dragging, as it's confusing otherwise */
- setup_pixels_per_second ();
- }
- Refresh ();
- } else if (property == AudioContentProperty::AUDIO_STREAMS) {
+ if (property == AudioContentProperty::AUDIO_STREAMS) {
recreate_views ();
}
}
_tracks = max (_tracks, t + 1);
}
- _time_axis_view->set_y (tracks() * track_height() + 32);
+ _time_axis_view->set_y (tracks() * track_height() + 64);
+ _reels_view->set_y (tracks() * track_height() + 32);
}
int