[Bf-blender-cvs] [37d1906b8fa] greasepencil-object: GPencil: Fix missing Sculpt Strokes panel
Antonio Vazquez
noreply at git.blender.org
Fri Nov 22 10:32:33 CET 2019
Commit: 37d1906b8fa3b928eabd4bafd80685c29917c446
Author: Antonio Vazquez
Date: Fri Nov 22 09:55:32 2019 +0100
Branches: greasepencil-object
https://developer.blender.org/rB37d1906b8fa3b928eabd4bafd80685c29917c446
GPencil: Fix missing Sculpt Strokes panel
===================================================================
M release/scripts/startup/bl_ui/properties_grease_pencil_common.py
===================================================================
diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
index ee5b760f0bf..ee46f3dbba0 100644
--- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
+++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
@@ -232,25 +232,26 @@ class GreasePencilSculptOptionsPanel:
brush = context.tool_settings.gpencil_sculpt_paint.brush
tool = brush.gpencil_sculpt_tool
- return bool(tool in {'SMOOTH', 'RANDOMIZE', 'SMOOTH'})
+ return bool(tool in {'SMOOTH', 'RANDOMIZE'})
def draw(self, context):
layout = self.layout
layout.use_property_split = True
layout.use_property_decorate = False
-
- brush = context.tool_settings.gpencil_sculpt_paint.brush
+ ts = context.tool_settings
+ brush = ts.gpencil_sculpt_paint.brush
+ gp_settings = brush.gpencil_settings
tool = brush.gpencil_sculpt_tool
if tool in {'SMOOTH', 'RANDOMIZE'}:
- layout.prop(brush, "use_edit_position", text="Affect Position")
- layout.prop(brush, "use_edit_strength", text="Affect Strength")
- layout.prop(brush, "use_edit_thickness", text="Affect Thickness")
+ layout.prop(gp_settings, "use_edit_position", text="Affect Position")
+ layout.prop(gp_settings, "use_edit_strength", text="Affect Strength")
+ layout.prop(gp_settings, "use_edit_thickness", text="Affect Thickness")
if tool == 'SMOOTH':
- layout.prop(brush, "use_edit_pressure")
+ layout.prop(gp_settings, "use_edit_pressure")
- layout.prop(brush, "use_edit_uv", text="Affect UV")
+ layout.prop(gp_settings, "use_edit_uv", text="Affect UV")
# GP Object Tool Settings
More information about the Bf-blender-cvs
mailing list