diff options
author | William Reynish <billrey@me.com> | 2019-05-16 15:14:13 +0300 |
---|---|---|
committer | William Reynish <billrey@me.com> | 2019-05-16 15:14:13 +0300 |
commit | a08a3d8bf0949139f2568c39375fae18ae532fa4 (patch) | |
tree | ade643f51c0fb7868e1e12e246db4fe51f96131a /release/scripts/startup/bl_ui/space_sequencer.py | |
parent | db5120603f8f6236d1417199f257e35e0eb8c00b (diff) |
UI: Match Sequencer Safe Areas with similar Camera Properties panel
Diffstat (limited to 'release/scripts/startup/bl_ui/space_sequencer.py')
-rw-r--r-- | release/scripts/startup/bl_ui/space_sequencer.py | 35 |
1 files changed, 32 insertions, 3 deletions
diff --git a/release/scripts/startup/bl_ui/space_sequencer.py b/release/scripts/startup/bl_ui/space_sequencer.py index 73a252885a8..d380ad89d3a 100644 --- a/release/scripts/startup/bl_ui/space_sequencer.py +++ b/release/scripts/startup/bl_ui/space_sequencer.py @@ -1568,14 +1568,42 @@ class SEQUENCER_PT_view_safe_areas(SequencerButtonsPanel_Output, Panel): self.layout.prop(st, "show_safe_areas", text="") def draw(self, context): - from .properties_data_camera import draw_display_safe_settings - layout = self.layout + layout.use_property_split = True + st = context.space_data + safe_data = context.scene.safe_areas + + layout.active = st.show_safe_areas + + col = layout.column() + + sub = col.column() + sub.prop(safe_data, "title", slider=True) + sub.prop(safe_data, "action", slider=True) + + +class SEQUENCER_PT_view_safe_areas_center_cut(SequencerButtonsPanel_Output, Panel): + bl_label = "Center-Cut Safe Areas" + bl_parent_id = "SEQUENCER_PT_view_safe_areas" + bl_options = {'DEFAULT_CLOSED'} + def draw_header(self, context): st = context.space_data + + layout = self.layout + layout.active = st.show_safe_areas + layout.prop(st, "show_safe_center", text="") + + def draw(self, context): + layout = self.layout + layout.use_property_split = True safe_data = context.scene.safe_areas + st = context.space_data - draw_display_safe_settings(layout, safe_data, st) + layout.active = st.show_safe_areas and st.show_safe_center + + col = layout.column() + col.prop(safe_data, "title_center", slider=True) class SEQUENCER_PT_modifiers(SequencerButtonsPanel, Panel): @@ -1716,6 +1744,7 @@ classes = ( SEQUENCER_PT_preview, SEQUENCER_PT_view, SEQUENCER_PT_view_safe_areas, + SEQUENCER_PT_view_safe_areas_center_cut, SEQUENCER_PT_modifiers, SEQUENCER_PT_info, |