[Bf-blender-cvs] [bae8ab3188b] blender2.8: UI: remove hack to align search properties

Campbell Barton noreply at git.blender.org
Fri Aug 24 04:05:15 CEST 2018


Commit: bae8ab3188b33635f90f840fccdc6517a3dae22b
Author: Campbell Barton
Date:   Fri Aug 24 10:51:53 2018 +1000
Branches: blender2.8
https://developer.blender.org/rBbae8ab3188b33635f90f840fccdc6517a3dae22b

UI: remove hack to align search properties

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

M	release/scripts/startup/bl_ui/properties_physics_cloth.py
M	release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
M	release/scripts/startup/bl_ui/properties_physics_smoke.py
M	release/scripts/startup/bl_ui/properties_physics_softbody.py
M	release/scripts/startup/bl_ui/properties_texture.py

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

diff --git a/release/scripts/startup/bl_ui/properties_physics_cloth.py b/release/scripts/startup/bl_ui/properties_physics_cloth.py
index 86ded4f9d01..d65be4e578a 100644
--- a/release/scripts/startup/bl_ui/properties_physics_cloth.py
+++ b/release/scripts/startup/bl_ui/properties_physics_cloth.py
@@ -95,11 +95,9 @@ class PHYSICS_PT_cloth(PhysicButtonsPanel, Panel):
         key = ob.data.shape_keys
 
         if key:
-            # Note: TODO prop_search doesn't align on the right.
             row = col.row(align=True)
             row.active = not cloth.use_dynamic_mesh
             row.prop_search(cloth, "rest_shape_key", key, "key_blocks", text="Rest Shape Key")
-            row.label(text="", icon='BLANK1')
 
 
 class PHYSICS_PT_cloth_pinning(PhysicButtonsPanel, Panel):
@@ -129,10 +127,7 @@ class PHYSICS_PT_cloth_pinning(PhysicButtonsPanel, Panel):
 
         col = flow.column()
 
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(cloth, "vertex_group_mass", ob, "vertex_groups", text="Mass Group")
-        row.label(text="", icon='BLANK1')
+        col.prop_search(cloth, "vertex_group_mass", ob, "vertex_groups", text="Mass Group")
 
         col = flow.column()
         col.prop(cloth, "pin_stiffness", text="Stiffness")
@@ -221,10 +216,7 @@ class PHYSICS_PT_cloth_self_collision(PhysicButtonsPanel, Panel):
         col.prop(cloth, "self_distance_min", slider=True, text="Distance")
 
         col = flow.column()
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(cloth, "vertex_group_self_collisions", ob, "vertex_groups", text="Vertex Group")
-        row.label(text="", icon='BLANK1')
+        col.prop_search(cloth, "vertex_group_self_collisions", ob, "vertex_groups", text="Vertex Group")
 
 
 class PHYSICS_PT_cloth_stiffness(PhysicButtonsPanel, Panel):
@@ -252,24 +244,19 @@ class PHYSICS_PT_cloth_stiffness(PhysicButtonsPanel, Panel):
         flow = layout.grid_flow(row_major=True, columns=0, even_columns=True, even_rows=False, align=True)
 
         col = flow.column()
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(
+        col.prop_search(
             cloth, "vertex_group_structural_stiffness", ob, "vertex_groups",
             text="Structural Group"
         )
-        row.label(text="", icon='BLANK1')
         col.prop(cloth, "structural_stiffness_max", text="Max")
 
         col.separator()
 
         col = flow.column()
-        row = col.row(align=True)
-        row.prop_search(
+        col.prop_search(
             cloth, "vertex_group_bending", ob, "vertex_groups",
             text="Bending Group"
         )
-        row.label(text="", icon='BLANK1')
         col.prop(cloth, "bending_stiffness_max", text="Max")
 
 
@@ -302,10 +289,7 @@ class PHYSICS_PT_cloth_sewing(PhysicButtonsPanel, Panel):
         col.separator()
 
         col = col.column()
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(cloth, "vertex_group_shrink", ob, "vertex_groups", text="Shrinking Group")
-        row.label(text="", icon='BLANK1')
+        col.prop_search(cloth, "vertex_group_shrink", ob, "vertex_groups", text="Shrinking Group")
 
         col = flow.column(align=True)
         col.prop(cloth, "shrink_min", text="Min")
diff --git a/release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py b/release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
index 9d52232e10c..424ad6ce5e1 100644
--- a/release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
+++ b/release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
@@ -397,10 +397,7 @@ class PHYSICS_PT_dp_canvas_output(PhysicButtonsPanel, Panel):
 
             col = flow.column()
 
-            # Note: TODO prop_search doesn't align on the right.
-            row = col.row(align=True)
-            row.prop_search(surface, "uv_layer", ob.data, "uv_layers", text="UV Map")
-            row.label(text="", icon='BLANK1')
+            col.prop_search(surface, "uv_layer", ob.data, "uv_layers", text="UV Map")
 
             col = flow.column()
             col.prop(surface, "image_fileformat")
@@ -539,16 +536,10 @@ class PHYSICS_PT_dp_canvas_initial_color(PhysicButtonsPanel, Panel):
 
         elif surface.init_color_type == 'TEXTURE':
             col.prop(surface, "init_texture")
-            # Note: TODO prop_search doesn't align on the right.
-            row = col.row(align=True)
-            row.prop_search(surface, "init_layername", ob.data, "uv_layers", text="UV Map")
-            row.label(text="", icon='BLANK1')
+            col.prop_search(surface, "init_layername", ob.data, "uv_layers", text="UV Map")
 
         elif surface.init_color_type == 'VERTEX_COLOR':
-            # Note: TODO prop_search doesn't align on the right.
-            row = col.row(align=True)
-            row.prop_search(surface, "init_layername", ob.data, "vertex_colors", text="Color Layer")
-            row.label(text="", icon='BLANK1')
+            col.prop_search(surface, "init_layername", ob.data, "vertex_colors", text="Color Layer")
 
 
 class PHYSICS_PT_dp_effects(PhysicButtonsPanel, Panel):
@@ -742,10 +733,7 @@ class PHYSICS_PT_dp_brush_source(PhysicButtonsPanel, Panel):
 
             col.separator()
 
-            # Note: TODO prop_search doesn't align on the right.
-            row = col.row(align=True)
-            row.prop_search(brush, "particle_system", ob, "particle_systems")
-            row.label(text="", icon='BLANK1')
+            col.prop_search(brush, "particle_system", ob, "particle_systems")
 
             if brush.particle_system:
                 col = flow.column()
diff --git a/release/scripts/startup/bl_ui/properties_physics_smoke.py b/release/scripts/startup/bl_ui/properties_physics_smoke.py
index bc8df5630e9..7f21b14e03c 100644
--- a/release/scripts/startup/bl_ui/properties_physics_smoke.py
+++ b/release/scripts/startup/bl_ui/properties_physics_smoke.py
@@ -123,13 +123,10 @@ class PHYSICS_PT_smoke_settings(PhysicButtonsPanel, Panel):
                 col.prop(flow_smoke, "smoke_flow_source", expand=False, text="Flow Source")
 
                 if flow_smoke.smoke_flow_source == 'PARTICLES':
-                    # Note: TODO prop_search doesn't align on the right.
-                    row = col.row(align=True)
-                    row.prop_search(
+                    col.prop_search(
                         flow_smoke, "particle_system", ob, "particle_systems",
                         text="Particle System"
                     )
-                    row.label(text="", icon='BLANK1')
                 else:
                     col.prop(flow_smoke, "surface_distance")
                     col.prop(flow_smoke, "volume_density")
@@ -153,10 +150,7 @@ class PHYSICS_PT_smoke_settings(PhysicButtonsPanel, Panel):
 
             col.separator()
 
-            # Note: TODO prop_search doesn't align on the right.
-            row = col.row(align=True)
-            row.prop_search(flow_smoke, "density_vertex_group", ob, "vertex_groups", text="Vertex Group")
-            row.label(text="", icon='BLANK1')
+            col.prop_search(flow_smoke, "density_vertex_group", ob, "vertex_groups", text="Vertex Group")
 
         elif md.smoke_type == 'COLLISION':
             coll = md.coll_settings
@@ -349,10 +343,7 @@ class PHYSICS_PT_smoke_flow_texture(PhysicButtonsPanel, Panel):
         sub.active = flow_smoke.use_texture
 
         if flow_smoke.texture_map_type == 'UV':
-            # Note: TODO prop_search doesn't align on the right.
-            row = sub.row(align=True)
-            row.prop_search(flow_smoke, "uv_layer", ob.data, "uv_layers")
-            row.label(text="", icon='BLANK1')
+            sub.prop_search(flow_smoke, "uv_layer", ob.data, "uv_layers")
 
         if flow_smoke.texture_map_type == 'AUTO':
             sub.prop(flow_smoke, "texture_size")
diff --git a/release/scripts/startup/bl_ui/properties_physics_softbody.py b/release/scripts/startup/bl_ui/properties_physics_softbody.py
index 595e462e1c3..7f1da6a4acb 100644
--- a/release/scripts/startup/bl_ui/properties_physics_softbody.py
+++ b/release/scripts/startup/bl_ui/properties_physics_softbody.py
@@ -84,10 +84,7 @@ class PHYSICS_PT_softbody_object(PhysicButtonsPanel, Panel):
         col = flow.column()
         col.prop(softbody, "mass")
 
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(softbody, "vertex_group_mass", ob, "vertex_groups", text="Control Point")
-        row.label(text="", icon='BLANK1')
+        col.prop_search(softbody, "vertex_group_mass", ob, "vertex_groups", text="Control Point")
 
 
 class PHYSICS_PT_softbody_simulation(PhysicButtonsPanel, Panel):
@@ -141,10 +138,7 @@ class PHYSICS_PT_softbody_goal(PhysicButtonsPanel, Panel):
 
         layout.active = softbody.use_goal and softbody_panel_enabled(md)
 
-        # Note: TODO prop_search doesn't align on the right.
-        row = layout.row(align=True)
-        row.prop_search(softbody, "vertex_group_goal", ob, "vertex_groups", text="Vertex Group")
-        row.label(text="", icon='BLANK1')
+        layout.prop_search(softbody, "vertex_group_goal", ob, "vertex_groups", text="Vertex Group")
 
 
 class PHYSICS_PT_softbody_goal_strenghts(PhysicButtonsPanel, Panel):
@@ -221,10 +215,7 @@ class PHYSICS_PT_softbody_edge(PhysicButtonsPanel, Panel):
 
         col = flow.column()
 
-        # Note: TODO prop_search doesn't align on the right.
-        row = col.row(align=True)
-        row.prop_search(softbody, "vertex_group_spring", ob, "vertex_groups", text="Springs")
-        row.label(text="", icon='BLANK1')
+        col.prop_search(softbody, "vertex_group_spring", ob, "vertex_groups", text="Springs")
 
         col.separator()
 
diff --git a/release/scripts/startup/bl_ui/properties_texture.py b/release/scripts/startup/bl_ui/properties_texture.py
index a4f6f753669..ae42e3f1d08 100644
--- a/release/scripts/startup/bl_ui/properties_texture.py
+++ b/release/scripts/startup/bl_ui/properties_text

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list