[Bf-blender-cvs] [a1ec1b3] master: Fix part of T43556 brush increase/decrease size operators do not update the UI sliders.

Antony Riakiotakis noreply at git.blender.org
Thu Feb 5 18:14:17 CET 2015


Commit: a1ec1b3974e81108f5d017d0a1fdcede7419ee99
Author: Antony Riakiotakis
Date:   Thu Feb 5 18:14:05 2015 +0100
Branches: master
https://developer.blender.org/rBa1ec1b3974e81108f5d017d0a1fdcede7419ee99

Fix part of T43556 brush increase/decrease size operators do not update
the UI sliders.

===================================================================

M	source/blender/editors/sculpt_paint/paint_ops.c

===================================================================

diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c
index ea5f77a..46d7b47 100644
--- a/source/blender/editors/sculpt_paint/paint_ops.c
+++ b/source/blender/editors/sculpt_paint/paint_ops.c
@@ -114,7 +114,7 @@ static int brush_scale_size_exec(bContext *C, wmOperator *op)
 					size--;
 				}
 			}
-			CLAMP(size, 1, 2000); // XXX magic number
+			CLAMP(size, 1, MAX_BRUSH_PIXEL_RADIUS); // XXX magic number, same as max for RNA
 
 			BKE_brush_size_set(scene, brush, size);
 		}
@@ -128,6 +128,8 @@ static int brush_scale_size_exec(bContext *C, wmOperator *op)
 
 			BKE_brush_unprojected_radius_set(scene, brush, unprojected_radius);
 		}
+
+		WM_main_add_notifier(NC_BRUSH | NA_EDITED, brush);
 	}
 
 	return OPERATOR_FINISHED;




More information about the Bf-blender-cvs mailing list