[Bf-blender-cvs] [6f3f107] master: Fix T37336: Toggle selecting a pose-bone from object mode would de-select all others.

Campbell Barton noreply at git.blender.org
Mon Nov 18 19:22:52 CET 2013


Commit: 6f3f107c5973cd68699f90256e5c0a7fc2dfb8fe
Author: Campbell Barton
Date:   Tue Nov 19 05:18:57 2013 +1100
http://developer.blender.org/rB6f3f107c5973cd68699f90256e5c0a7fc2dfb8fe

Fix T37336: Toggle selecting a pose-bone from object mode would de-select all others.

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

M	source/blender/editors/armature/pose_select.c

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

diff --git a/source/blender/editors/armature/pose_select.c b/source/blender/editors/armature/pose_select.c
index b3277c1..765437f 100644
--- a/source/blender/editors/armature/pose_select.c
+++ b/source/blender/editors/armature/pose_select.c
@@ -129,9 +129,16 @@ int ED_do_pose_selectbuffer(Scene *scene, Base *base, unsigned int *buffer, shor
 		 * note, special exception for armature mode so we can do multi-select
 		 * we could check for multi-select explicitly but think its fine to
 		 * always give predictable behavior in weight paint mode - campbell */
-		if ((!extend && !deselect && !toggle) ||
-		    ((ob_act && (ob_act != ob) && (ob_act->mode & OB_MODE_WEIGHT_PAINT) == 0)))
-		{
+		if ((ob_act == NULL) || ((ob_act != ob) && (ob_act->mode & OB_MODE_WEIGHT_PAINT) == 0)) {
+			/* when we are entering into posemode via toggle-select,
+			 * frop another active object - always select the bone. */
+			if (!extend && !deselect && toggle) {
+				/* re-select below */
+				nearBone->flag &= ~BONE_SELECTED;
+			}
+		}
+
+		if (!extend && !deselect && !toggle) {
 			ED_pose_deselectall(ob, 0);
 			nearBone->flag |= (BONE_SELECTED | BONE_TIPSEL | BONE_ROOTSEL);
 			arm->act_bone = nearBone;




More information about the Bf-blender-cvs mailing list