[Bf-blender-cvs] [8c4b5ac4c1b] master: Fix T62007: Dial 3d being drawn out of rotating tool.

mano-wii noreply at git.blender.org
Wed Feb 27 18:46:51 CET 2019


Commit: 8c4b5ac4c1b496e04bc44ed25f0e89335445ba51
Author: mano-wii
Date:   Wed Feb 27 13:37:12 2019 -0300
Branches: master
https://developer.blender.org/rB8c4b5ac4c1b496e04bc44ed25f0e89335445ba51

Fix T62007: Dial 3d being drawn out of rotating tool.

It was being drawn when any Gizmo was highlighted.
There are several ways to solve this (creating a new parameter to the operator, checking the gizmos in the invoke or creating a global context).
Also, for a micro-optimization, all of those conditions in the `drawDial3d` could be done once in the invoke.
But since all of these changes involve changing the customdata (`TransInfo`), which is already a bit confusing with so many members, I thought it best to make minimal changes.

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

M	source/blender/editors/transform/transform_gizmo_3d.c

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

diff --git a/source/blender/editors/transform/transform_gizmo_3d.c b/source/blender/editors/transform/transform_gizmo_3d.c
index ff77653a72d..e1066315508 100644
--- a/source/blender/editors/transform/transform_gizmo_3d.c
+++ b/source/blender/editors/transform/transform_gizmo_3d.c
@@ -1292,7 +1292,7 @@ static void gizmo_xform_message_subscribe(
 void drawDial3d(const TransInfo *t)
 {
 	if (t->mode == TFM_ROTATION && t->spacetype == SPACE_VIEW3D) {
-		wmGizmo *gz = wm_gizmomap_highlight_get(t->ar->gizmo_map);
+		wmGizmo *gz = wm_gizmomap_modal_get(t->ar->gizmo_map);
 		if (gz == NULL) {
 			/* We only draw Dial3d if the operator has been called by a gizmo. */
 			return;



More information about the Bf-blender-cvs mailing list