[Bf-blender-cvs] [389fc62f6c4] master: Fix T72094: Multiple snap targets don't work when Increment is enabled
mano-wii
noreply at git.blender.org
Mon Jan 13 17:47:53 CET 2020
Commit: 389fc62f6c4e039902c94c3da36fd24a351c8a8d
Author: mano-wii
Date: Mon Jan 13 13:47:05 2020 -0300
Branches: master
https://developer.blender.org/rB389fc62f6c4e039902c94c3da36fd24a351c8a8d
Fix T72094: Multiple snap targets don't work when Increment is enabled
The `poll_modal_item` was too restrictive.
`!validSnap(t)` already solves these cases, but for better readability
(and efficiency), I found it best to keep the `tsnap.mode` test.
===================================================================
M source/blender/editors/transform/transform.c
===================================================================
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c
index 9a98a2b8a00..62a61a3a05a 100644
--- a/source/blender/editors/transform/transform.c
+++ b/source/blender/editors/transform/transform.c
@@ -856,7 +856,7 @@ static bool transform_modal_item_poll(const wmOperator *op, int value)
if (t->spacetype != SPACE_VIEW3D) {
return false;
}
- else if (t->tsnap.mode & (SCE_SNAP_MODE_INCREMENT | SCE_SNAP_MODE_GRID)) {
+ else if ((t->tsnap.mode & ~(SCE_SNAP_MODE_INCREMENT | SCE_SNAP_MODE_GRID)) == 0) {
return false;
}
else if (!validSnap(t)) {
More information about the Bf-blender-cvs
mailing list