VSE: New Change Scene option in Change menu

This is a new option in `C` key menu.

Reviewed By: mendio, ISS

Maniphest Tasks: T97711

Differential Revision: https://developer.blender.org/D14807
This commit is contained in:
2022-05-16 19:41:50 +02:00
parent 6065fbb543
commit 205c6d8d08
4 changed files with 86 additions and 0 deletions

View File

@@ -611,7 +611,16 @@ class SEQUENCER_MT_change(Menu):
strip = context.active_sequence_strip
layout.operator_context = 'INVOKE_REGION_WIN'
if strip and strip.type == 'SCENE':
bpy_data_scenes_len = len(bpy.data.scenes)
if bpy_data_scenes_len > 10:
layout.operator_context = 'INVOKE_DEFAULT'
layout.operator("sequencer.change_scene", text="Change Scene...")
elif bpy_data_scenes_len > 1:
layout.operator_menu_enum("sequencer.change_scene", "scene", text="Change Scene")
del bpy_data_scenes_len
layout.operator_context = 'INVOKE_DEFAULT'
layout.operator_menu_enum("sequencer.change_effect_input", "swap")
layout.operator_menu_enum("sequencer.change_effect_type", "type")
prop = layout.operator("sequencer.change_path", text="Path/Files")