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:
authorCampbell Barton <ideasman42@gmail.com>2018-12-19 04:26:33 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-12-19 04:30:16 +0300
commitfd42fe661612455c2d2558481c6587c0b7d95366 (patch)
tree529cb8fba092d866c9b89d460ac2c880f94ae1e8 /source/blender/editors/transform/transform_gizmo_3d.c
parentbb4ed5ce39cb2c07bfd97deb46a30b5505bbbf76 (diff)
Fix T57139: Transform overlay shows even when disabled
Transform bypasses the gizmo API for drawing overlays, so custom checks are needed. Also don't draw the gizmo in other windows when transforming.
Diffstat (limited to 'source/blender/editors/transform/transform_gizmo_3d.c')
-rw-r--r--source/blender/editors/transform/transform_gizmo_3d.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/editors/transform/transform_gizmo_3d.c b/source/blender/editors/transform/transform_gizmo_3d.c
index 1913e35c1da..5a26245c14d 100644
--- a/source/blender/editors/transform/transform_gizmo_3d.c
+++ b/source/blender/editors/transform/transform_gizmo_3d.c
@@ -785,7 +785,7 @@ int ED_transform_calc_gizmo_stats(
const bool use_mat_local = true;
for (bGPDlayer *gpl = gpd->layers.first; gpl; gpl = gpl->next) {
/* only editable and visible layers are considered */
-
+
if (gpencil_layer_is_editable(gpl) && (gpl->actframe != NULL)) {
/* calculate difference matrix */
@@ -1822,6 +1822,9 @@ static bool WIDGETGROUP_gizmo_poll(const struct bContext *C, struct wmGizmoGroup
if (v3d->gizmo_flag & (V3D_GIZMO_HIDE | V3D_GIZMO_HIDE_TOOL)) {
return false;
}
+ if (G.moving & (G_TRANSFORM_OBJ | G_TRANSFORM_EDIT)) {
+ return false;
+ }
return true;
}
@@ -1876,6 +1879,9 @@ static bool WIDGETGROUP_xform_cage_poll(const bContext *C, wmGizmoGroupType *gzg
if (v3d->gizmo_flag & (V3D_GIZMO_HIDE | V3D_GIZMO_HIDE_TOOL)) {
return false;
}
+ if (G.moving & (G_TRANSFORM_OBJ | G_TRANSFORM_EDIT)) {
+ return false;
+ }
return true;
}