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:
authorJacques Lucke <jacques@blender.org>2020-02-28 11:01:15 +0300
committerJacques Lucke <jacques@blender.org>2020-02-28 11:01:15 +0300
commit4ed7334ef617abc3f3fabbca4fe3e128f74020c2 (patch)
treeedd7dcae4a5b9ed764d4471b4b63f992ede777a7 /release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
parentb92b1a4fe56338c7a66dda4f27426c10e070b11c (diff)
parent9cac5fa681c55edcf6e856e59e07e90e2ae25965 (diff)
Merge branch 'master' into functions
Diffstat (limited to 'release/scripts/startup/bl_ui/space_toolsystem_toolbar.py')
-rw-r--r--release/scripts/startup/bl_ui/space_toolsystem_toolbar.py33
1 files changed, 22 insertions, 11 deletions
diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
index cd1fc49ac8b..2c79ceb5763 100644
--- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
@@ -18,6 +18,9 @@
# <pep8 compliant>
+# For documentation on tool definitions: see "bl_ui.space_toolsystem_common.ToolDef"
+# where there are comments for each field and their use.
+
# For now group all tools together
# we may want to move these into per space-type files.
#
@@ -608,15 +611,6 @@ class _defs_edit_mesh:
region_type = context.region.type
if not extra:
- if props.offset_type == 'PERCENT':
- layout.prop(props, "offset_pct")
- else:
- offset_text = "Width"
- if props.offset_type == 'DEPTH':
- offset_text = "Depth"
- elif props.offset_type == 'OFFSET':
- offset_text = "Offset"
- layout.prop(props, "offset", text=offset_text)
if region_type == 'TOOL_HEADER':
layout.prop(props, "offset_type", text="")
else:
@@ -1136,8 +1130,25 @@ class _defs_weight_paint:
def draw_settings(context, layout, tool):
brush = context.tool_settings.weight_paint.brush
if brush is not None:
- layout.prop(brush, "weight", slider=True)
- layout.prop(brush, "strength", slider=True)
+ from bl_ui.properties_paint_common import UnifiedPaintPanel
+ UnifiedPaintPanel.prop_unified(
+ layout,
+ context,
+ brush,
+ "weight",
+ unified_name="use_unified_weight",
+ slider=True,
+ header=True
+ )
+ UnifiedPaintPanel.prop_unified(
+ layout,
+ context,
+ brush,
+ "strength",
+ unified_name="use_unified_strength",
+ header=True
+ )
+
props = tool.operator_properties("paint.weight_gradient")
layout.prop(props, "type", expand=True)