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>2014-05-19 13:25:59 +0400
committerCampbell Barton <ideasman42@gmail.com>2014-05-19 13:25:59 +0400
commit3a3b990b2d35385aa564be6115411edaf9165a08 (patch)
tree7df72c18c27cbbff5470bbcb6cd9d7df039ff208 /source/blender/editors/transform/transform_ops.c
parentf8278e5479a56d7742e820821ab16c5c3c3fab75 (diff)
Workaround T40241: Vertex snapping snaps to wrong place
Diffstat (limited to 'source/blender/editors/transform/transform_ops.c')
-rw-r--r--source/blender/editors/transform/transform_ops.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/transform/transform_ops.c b/source/blender/editors/transform/transform_ops.c
index f27ea4793fe..c6c9e84a125 100644
--- a/source/blender/editors/transform/transform_ops.c
+++ b/source/blender/editors/transform/transform_ops.c
@@ -391,6 +391,14 @@ static int transform_modal(bContext *C, wmOperator *op, const wmEvent *event)
exit_code = transformEvent(t, event);
t->context = NULL;
+ /* XXX, workaround: active needs to be calculated before transforming,
+ * since we're not reading from 'td->center' in this case. see: T40241 */
+ if (t->tsnap.target == SCE_SNAP_TARGET_ACTIVE) {
+ if ((t->tsnap.status & TARGET_INIT) == 0) {
+ t->tsnap.targetSnap(t);
+ }
+ }
+
transformApply(C, t);
exit_code |= transformEnd(C, t);