diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2021-06-09 13:11:38 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2021-06-09 13:52:44 +0300 |
commit | f087a225dcc445dfc56d34f15ae967e4121f9838 (patch) | |
tree | a218a1d00dbd950fcf845847d3662f582b1ac2db /release/scripts/startup/bl_ui/properties_grease_pencil_common.py | |
parent | dd98f6b55cdf7da3c60bb9278bcf4c9baeb49507 (diff) |
GPencil: Hide Brush panels for some tools
Some tools don't use brush and the panel must be hidden.
Reviewed By: mendio
Differential Revision: https://developer.blender.org/D11518
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_grease_pencil_common.py')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_grease_pencil_common.py | 15 |
1 files changed, 0 insertions, 15 deletions
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 2e89ddcb1d4..0da0716e850 100644 --- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py +++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py @@ -179,21 +179,6 @@ class GreasePencilBrushFalloff: bl_label = "Falloff" bl_options = {'DEFAULT_CLOSED'} - @classmethod - def poll(cls, context): - ts = context.tool_settings - settings = None - if context.mode == 'PAINT_GPENCIL': - settings = ts.gpencil_paint - if context.mode == 'SCULPT_GPENCIL': - settings = ts.gpencil_sculpt_paint - elif context.mode == 'WEIGHT_GPENCIL': - settings = ts.gpencil_weight_paint - elif context.mode == 'VERTEX_GPENCIL': - settings = ts.gpencil_vertex_paint - - return (settings and settings.brush and settings.brush.curve) - def draw(self, context): layout = self.layout ts = context.tool_settings |