Fix #145960: VSE: Modifier panel shows up in preview region

This was happening because the strip modifier types register
their panels when the editor is created, but the poll functions
of these panels did not check for the view type.

To fix this, add a condition to the `modifier_ui_poll`
that checks if the view type is not `SEQ_VIEW_PREVIEW`
when the panel is added to a sequencer space.

Pull Request: https://projects.blender.org/blender/blender/pulls/145964
This commit is contained in:
Falk David
2025-09-09 12:31:11 +02:00
committed by Falk David
parent 3611b8a592
commit 9c8eb0bcb9

View File

@@ -19,6 +19,7 @@
#include "DNA_mask_types.h"
#include "DNA_sequence_types.h"
#include "DNA_space_types.h"
#include "BKE_colortools.hh"
#include "BKE_screen.hh"
@@ -181,6 +182,12 @@ bool modifier_ui_poll(const bContext *C, PanelType * /*pt*/)
if (!sequencer_scene) {
return false;
}
if (const SpaceSeq *sseq = CTX_wm_space_seq(C)) {
/* Only show modifiers in the sequencer view types, not the preview. */
if (sseq->view == SEQ_VIEW_PREVIEW) {
return false;
}
}
Strip *active_strip = seq::select_active_get(sequencer_scene);
return active_strip != nullptr;
}