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:
authorJoseph Eagar <joeedh@gmail.com>2022-04-25 22:26:02 +0300
committerJoseph Eagar <joeedh@gmail.com>2022-04-25 22:26:02 +0300
commit38eed4ada363861abc6d44fee5816a2c384fea22 (patch)
tree0c43154f2880a48ebf7a1753dddf2cf3ac72becc
parent296d734344139db6bc092082eaf6ee94458d5506 (diff)
Fix T97553: SCULPT_handles_colors_report called for non-sculpt brushes
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 93a60b9908e..bfe28cb09e1 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -5447,8 +5447,10 @@ static int sculpt_brush_stroke_invoke(bContext *C, wmOperator *op, const wmEvent
sculpt_brush_stroke_init(C, op);
Object *ob = CTX_data_active_object(C);
+ Sculpt *sd = CTX_data_tool_settings(C)->sculpt;
+ Brush *brush = BKE_paint_brush(&sd->paint);
- if (!SCULPT_handles_colors_report(ob->sculpt, op->reports)) {
+ if (SCULPT_TOOL_NEEDS_COLOR(brush->sculpt_tool) && !SCULPT_handles_colors_report(ob->sculpt, op->reports)) {
return OPERATOR_CANCELLED;
}