Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Fog <tintwotin>2020-05-28 19:11:53 +0300
committerHans Goudey <h.goudey@me.com>2020-05-28 19:11:53 +0300
commita099478cad7e7839ffd13937733396452bef872d (patch)
tree43df0a7426b50a899238351ad65d27376311f5ca
parent3923062d13b23b3b55d163b46bfad65a34b7ccd5 (diff)
UI: Use Heading to Remove Text strip Shadow Subpanel
The new "heading=" option allows for a more simple way to expose the Text strip Shadow operator. Differential Revision: https://developer.blender.org/D7535
-rw-r--r--release/scripts/startup/bl_ui/space_sequencer.py34
1 files changed, 8 insertions, 26 deletions
diff --git a/release/scripts/startup/bl_ui/space_sequencer.py b/release/scripts/startup/bl_ui/space_sequencer.py
index ca25c29960c..c146d374d22 100644
--- a/release/scripts/startup/bl_ui/space_sequencer.py
+++ b/release/scripts/startup/bl_ui/space_sequencer.py
@@ -1195,31 +1195,14 @@ class SEQUENCER_PT_effect_text_style(SequencerButtonsPanel, Panel):
col.prop(strip, "font_size")
col.prop(strip, "color")
-
-class SEQUENCER_PT_effect_text_style_shadow(SequencerButtonsPanel, Panel):
- bl_label = "Shadow"
- bl_parent_id = "SEQUENCER_PT_effect_text_style"
- bl_options = {'DEFAULT_CLOSED'}
- bl_category = "Strip"
-
- @classmethod
- def poll(cls, context):
- strip = act_strip(context)
- return strip.type != 'SOUND'
-
- def draw_header(self, context):
- strip = act_strip(context)
- self.layout.prop(strip, "use_shadow", text="")
-
- def draw(self, context):
- strip = act_strip(context)
- layout = self.layout
- layout.use_property_split = True
-
- layout.active = strip.use_shadow and (not strip.mute)
-
- col = layout.column(align=True)
- col.prop(strip, "shadow_color", text="Color")
+ row = layout.row(align=True, heading="Shadow")
+ row.use_property_decorate = False
+ sub = row.row(align=True)
+ sub.prop(strip, "use_shadow", text="")
+ subsub = sub.row(align=True)
+ subsub.active = strip.use_shadow and (not strip.mute)
+ subsub.prop(strip, "shadow_color", text="")
+ row.prop_decorator(strip, "shadow_color")
class SEQUENCER_PT_source(SequencerButtonsPanel, Panel):
@@ -2249,7 +2232,6 @@ classes = (
SEQUENCER_PT_mask,
SEQUENCER_PT_effect_text_style,
SEQUENCER_PT_effect_text_layout,
- SEQUENCER_PT_effect_text_style_shadow,
SEQUENCER_PT_time,
SEQUENCER_PT_source,