[Bf-blender-cvs] [4c26bb02327] master: UI: Show Mask Display Options Conistently

Aaron Carlisle noreply at git.blender.org
Sun Aug 8 22:09:30 CEST 2021


Commit: 4c26bb02327f0e836e55929d900b2f50d303f433
Author: Aaron Carlisle
Date:   Sun Aug 8 16:09:23 2021 -0400
Branches: master
https://developer.blender.org/rB4c26bb02327f0e836e55929d900b2f50d303f433

UI: Show Mask Display Options Conistently

This commit makes the display options for mask only show in the header for the clip and image editors.
Prior to this change they would display in the header for the clip editor and in the sidebar for the image editors.

===================================================================

M	release/scripts/startup/bl_ui/properties_mask_common.py
M	release/scripts/startup/bl_ui/space_clip.py
M	release/scripts/startup/bl_ui/space_image.py

===================================================================

diff --git a/release/scripts/startup/bl_ui/properties_mask_common.py b/release/scripts/startup/bl_ui/properties_mask_common.py
index 09a1f40d3a9..40a704a65dd 100644
--- a/release/scripts/startup/bl_ui/properties_mask_common.py
+++ b/release/scripts/startup/bl_ui/properties_mask_common.py
@@ -237,9 +237,8 @@ class MASK_PT_point:
 class MASK_PT_display:
     # subclasses must define...
     # ~ bl_space_type = 'CLIP_EDITOR'
-    # ~ bl_region_type = 'UI'
+    # ~ bl_region_type = 'HEADER'
     bl_label = "Mask Display"
-    bl_options = {'DEFAULT_CLOSED'}
 
     @classmethod
     def poll(cls, context):
diff --git a/release/scripts/startup/bl_ui/space_clip.py b/release/scripts/startup/bl_ui/space_clip.py
index afbc3abf302..ae106f893d3 100644
--- a/release/scripts/startup/bl_ui/space_clip.py
+++ b/release/scripts/startup/bl_ui/space_clip.py
@@ -1156,12 +1156,6 @@ class CLIP_PT_mask_layers(MASK_PT_layers, Panel):
     bl_category = "Mask"
 
 
-class CLIP_PT_mask_display(MASK_PT_display, Panel):
-    bl_space_type = 'CLIP_EDITOR'
-    bl_region_type = 'HEADER'
-    bl_category = "Mask"
-
-
 class CLIP_PT_active_mask_spline(MASK_PT_spline, Panel):
     bl_space_type = 'CLIP_EDITOR'
     bl_region_type = 'UI'
@@ -1191,6 +1185,11 @@ class CLIP_PT_tools_mask_tools(MASK_PT_tools, Panel):
     bl_region_type = 'TOOLS'
     bl_category = "Mask"
 
+
+class CLIP_PT_mask_display(MASK_PT_display, Panel):
+    bl_space_type = 'CLIP_EDITOR'
+    bl_region_type = 'HEADER'
+
 # --- end mask ---
 
 
diff --git a/release/scripts/startup/bl_ui/space_image.py b/release/scripts/startup/bl_ui/space_image.py
index 061c5b8cd34..dcb0ab2e9e5 100644
--- a/release/scripts/startup/bl_ui/space_image.py
+++ b/release/scripts/startup/bl_ui/space_image.py
@@ -817,7 +817,7 @@ class IMAGE_HT_header(Header):
                 row.prop(sima, "show_stereo_3d", text="")
             if show_maskedit:
                 row = layout.row()
-                row.popover(panel='CLIP_PT_mask_display')
+                row.popover(panel='IMAGE_PT_mask_display')
 
             # layers.
             layout.template_image_layers(ima, iuser)
@@ -911,8 +911,7 @@ class IMAGE_PT_active_mask_point(MASK_PT_point, Panel):
 
 class IMAGE_PT_mask_display(MASK_PT_display, Panel):
     bl_space_type = 'IMAGE_EDITOR'
-    bl_region_type = 'UI'
-    bl_category = "Mask"
+    bl_region_type = 'HEADER'
 
 
 # --- end mask ---



More information about the Bf-blender-cvs mailing list