diff options
author | Richard Antalik <richardantalik@gmail.com> | 2022-04-22 03:48:51 +0300 |
---|---|---|
committer | Richard Antalik <richardantalik@gmail.com> | 2022-04-22 03:51:10 +0300 |
commit | 48f369d63add246623828bbaf56631703c75f29e (patch) | |
tree | efa0116c4aa8aa421697e0faa32ca82b7d4dca72 /source | |
parent | 30acc5f9cde7e94713600b8481837bda996f9753 (diff) |
Fix: VSE channels region visible in preview
Hide region for preview and sequencer/preview combined view.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/editors/space_sequencer/space_sequencer.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/source/blender/editors/space_sequencer/space_sequencer.c b/source/blender/editors/space_sequencer/space_sequencer.c index 0a0669e02e4..89bff839481 100644 --- a/source/blender/editors/space_sequencer/space_sequencer.c +++ b/source/blender/editors/space_sequencer/space_sequencer.c @@ -331,6 +331,31 @@ static void sequencer_refresh(const bContext *C, ScrArea *area) break; } + ARegion *region_channels = sequencer_find_region(area, RGN_TYPE_CHANNELS); + if (sseq->view == SEQ_VIEW_SEQUENCE) { + if (region_channels && (region_channels->flag & RGN_FLAG_HIDDEN)) { + region_channels->flag &= ~RGN_FLAG_HIDDEN; + region_channels->v2d.flag &= ~V2D_IS_INIT; + view_changed = true; + } + if (region_channels && region_channels->alignment != RGN_ALIGN_LEFT) { + region_channels->alignment = RGN_ALIGN_LEFT; + view_changed = true; + } + } + else { + if (region_channels && !(region_channels->flag & RGN_FLAG_HIDDEN)) { + region_channels->flag |= RGN_FLAG_HIDDEN; + region_channels->v2d.flag &= ~V2D_IS_INIT; + WM_event_remove_handlers((bContext *)C, ®ion_channels->handlers); + view_changed = true; + } + if (region_channels && region_channels->alignment != RGN_ALIGN_NONE) { + region_channels->alignment = RGN_ALIGN_NONE; + view_changed = true; + } + } + if (view_changed) { ED_area_init(wm, window, area); ED_area_tag_redraw(area); |