From adf9ff6359c57a715472b69ed1a6b155e48e2cdb Mon Sep 17 00:00:00 2001 From: Peter Fog Date: Mon, 1 Jun 2020 05:32:36 +0200 Subject: VSE UI: Add a proxy menu to Preview/View menu Add Proxy Setup, Build and View to a menu in the Preview View menu. Reviewed By: ISS, billreynish, pablovazquez Differential Revision: https://developer.blender.org/D7734 --- release/scripts/startup/bl_ui/space_sequencer.py | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/release/scripts/startup/bl_ui/space_sequencer.py b/release/scripts/startup/bl_ui/space_sequencer.py index 7cb8c1d7ca2..2de047730b8 100644 --- a/release/scripts/startup/bl_ui/space_sequencer.py +++ b/release/scripts/startup/bl_ui/space_sequencer.py @@ -244,6 +244,20 @@ class SEQUENCER_MT_preview_zoom(Menu): layout.operator_context = 'INVOKE_DEFAULT' +class SEQUENCER_MT_proxy(Menu): + bl_label = "Proxy" + + def draw(self, context): + layout = self.layout + + st = context.space_data + col = layout.column() + col.operator("sequencer.enable_proxies", text="Setup") + col.operator("sequencer.rebuild_proxy", text="Rebuild") + col.enabled = selected_sequences_len(context) >= 1 + layout.prop(st, "proxy_render_size", text="") + + class SEQUENCER_MT_view(Menu): bl_label = "View" @@ -291,6 +305,10 @@ class SEQUENCER_MT_view(Menu): layout.operator("view2d.zoom_border", text="Zoom") layout.menu("SEQUENCER_MT_preview_zoom") + layout.separator() + + layout.menu("SEQUENCER_MT_proxy") + layout.operator_context = 'INVOKE_DEFAULT' if is_sequencer_view: @@ -773,9 +791,6 @@ class SEQUENCER_MT_strip(Menu): layout.separator() layout.menu("SEQUENCER_MT_strip_input") - layout.separator() - layout.operator("sequencer.rebuild_proxy") - class SEQUENCER_MT_context_menu(Menu): bl_label = "Sequencer Context Menu" @@ -2202,6 +2217,7 @@ classes = ( SEQUENCER_MT_view_cache, SEQUENCER_MT_view_toggle, SEQUENCER_MT_preview_zoom, + SEQUENCER_MT_proxy, SEQUENCER_MT_select_playhead, SEQUENCER_MT_select_handle, SEQUENCER_MT_select_channel, -- cgit v1.2.3