From d70cfb90e0fab7ba56c02b9016bcd5a54ebf2398 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Fri, 14 May 2021 00:44:23 +0200 Subject: Fix Sculpt tools showing the cursor of the previous active brush When using a tool that is not a brush, the previously used brush preset will still be active in the tool settings, so the cursor will draw its custom reviews. This checks if the current active tool is a brush before drawing its previews. If it is not a brush tools, it draws a default white cursor. Reviewed By: sergey Differential Revision: https://developer.blender.org/D9418 --- source/blender/editors/sculpt_paint/paint_intern.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/editors/sculpt_paint/paint_intern.h') diff --git a/source/blender/editors/sculpt_paint/paint_intern.h b/source/blender/editors/sculpt_paint/paint_intern.h index 3ca0d853d6a..3f5093222e9 100644 --- a/source/blender/editors/sculpt_paint/paint_intern.h +++ b/source/blender/editors/sculpt_paint/paint_intern.h @@ -87,7 +87,7 @@ struct ViewContext *paint_stroke_view_context(struct PaintStroke *stroke); void *paint_stroke_mode_data(struct PaintStroke *stroke); float paint_stroke_distance_get(struct PaintStroke *stroke); void paint_stroke_set_mode_data(struct PaintStroke *stroke, void *mode_data); -bool paint_poll(struct bContext *C); +bool PAINT_brush_tool_poll(struct bContext *C); void paint_cursor_start(struct Paint *p, bool (*poll)(struct bContext *C)); void paint_cursor_delete_textures(void); -- cgit v1.2.3