[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [54159] trunk/blender/source/blender/ editors/transform/transform.c: Bugfix [#34019] Limit Constraints still affected transforms when turned off

Joshua Leung aligorith at gmail.com
Tue Jan 29 00:57:09 CET 2013


Revision: 54159
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=54159
Author:   aligorith
Date:     2013-01-28 23:57:02 +0000 (Mon, 28 Jan 2013)
Log Message:
-----------
Bugfix [#34019] Limit Constraints still affected transforms when turned off

Limit Constraints (i.e. Limit Location/Rotation/Scale/Distance) with 'For
Transform' option enabled would still be applied when transforming objects even
when they were turned off using the eye icon in the constraint panel headers.
The "off" flag was never added to the checks for muted or disabled constraints
to be skipped here.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/transform/transform.c

Modified: trunk/blender/source/blender/editors/transform/transform.c
===================================================================
--- trunk/blender/source/blender/editors/transform/transform.c	2013-01-28 23:06:27 UTC (rev 54158)
+++ trunk/blender/source/blender/editors/transform/transform.c	2013-01-28 23:57:02 UTC (rev 54159)
@@ -2336,7 +2336,7 @@
 			ListBase targets = {NULL, NULL};
 			
 			/* only consider constraint if enabled */
-			if (con->flag & CONSTRAINT_DISABLE) continue;
+			if (con->flag & (CONSTRAINT_DISABLE | CONSTRAINT_OFF)) continue;
 			if (con->enforce == 0.0f) continue;
 			
 			/* only use it if it's tagged for this purpose (and the right type) */
@@ -2427,7 +2427,7 @@
 		/* Evaluate valid constraints */
 		for (con = td->con; con; con = con->next) {
 			/* only consider constraint if enabled */
-			if (con->flag & CONSTRAINT_DISABLE) continue;
+			if (con->flag & (CONSTRAINT_DISABLE | CONSTRAINT_OFF)) continue;
 			if (con->enforce == 0.0f) continue;
 
 			/* we're only interested in Limit-Rotation constraints */
@@ -2517,7 +2517,7 @@
 		/* Evaluate valid constraints */
 		for (con = td->con; con; con = con->next) {
 			/* only consider constraint if enabled */
-			if (con->flag & CONSTRAINT_DISABLE) continue;
+			if (con->flag & (CONSTRAINT_DISABLE | CONSTRAINT_OFF)) continue;
 			if (con->enforce == 0.0f) continue;
 			
 			/* we're only interested in Limit-Scale constraints */




More information about the Bf-blender-cvs mailing list