Fix: VSE: Runtime error for change effect menu on non-effects

The "change" menu (accessible through C) would spit out an
error if hovering over the "Change effect type" menu when the
active strip was not an effect.

Pull Request: https://projects.blender.org/blender/blender/pulls/140692
This commit is contained in:
John Kiril Swenson
2025-06-20 23:55:59 +02:00
committed by John Kiril Swenson
parent 5c25a24528
commit 083cbe202a

View File

@@ -660,8 +660,14 @@ class SEQUENCER_MT_change(Menu):
del bpy_data_scenes_len
layout.operator_context = 'INVOKE_DEFAULT'
layout.menu("SEQUENCER_MT_strip_effect_change")
layout.operator("sequencer.swap_inputs")
if strip.type in {
'CROSS', 'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER',
'GAMMA_CROSS', 'MULTIPLY', 'WIPE', 'GLOW',
'TRANSFORM', 'SPEED', 'MULTICAM', 'ADJUSTMENT',
'GAUSSIAN_BLUR',
}:
layout.menu("SEQUENCER_MT_strip_effect_change")
layout.operator("sequencer.swap_inputs")
props = layout.operator("sequencer.change_path", text="Path/Files")
if strip: