diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-07-08 03:06:11 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-07-08 03:15:03 +0300 |
commit | 8346417d09240c129c5688560180aec37bc4c89a (patch) | |
tree | c0f4586157ca559baee3a48601e28f6c0cde1524 /source/blender | |
parent | 695e025c82ab3ea72a4eb8f0eb11bc7af4954d29 (diff) |
Fix crash displaying the sequencer without a valid 'scene->ed'
Regression in 45d54ea67f9440d1c4ef89b3257ee92159de2599
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/space_sequencer/sequencer_draw.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/source/blender/editors/space_sequencer/sequencer_draw.c b/source/blender/editors/space_sequencer/sequencer_draw.c index 82283b03fc8..8371a634a78 100644 --- a/source/blender/editors/space_sequencer/sequencer_draw.c +++ b/source/blender/editors/space_sequencer/sequencer_draw.c @@ -2479,13 +2479,14 @@ void draw_timeline_seq_display(const bContext *C, ARegion *region) const SpaceSeq *sseq = CTX_wm_space_seq(C); View2D *v2d = ®ion->v2d; - UI_view2d_view_ortho(v2d); - draw_cache_view(C); - - if (scene->ed && scene->ed->over_flag & SEQ_EDIT_OVERLAY_SHOW) { - draw_overlap_frame_indicator(scene, v2d); + if (scene->ed != NULL) { + UI_view2d_view_ortho(v2d); + draw_cache_view(C); + if (scene->ed->over_flag & SEQ_EDIT_OVERLAY_SHOW) { + draw_overlap_frame_indicator(scene, v2d); + } + UI_view2d_view_restore(C); } - UI_view2d_view_restore(C); ED_time_scrub_draw_current_frame(region, scene, !(sseq->flag & SEQ_DRAWFRAMES), true); UI_view2d_scrollers_draw(v2d, NULL); |