From 807b6c4848723949d929fbcb6620977680e6f8d0 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 18 Jul 2019 12:22:32 +1000 Subject: Revert "Fix T66949: Can't select bones from multiple objects in wpaint mode" This reverts commit 9e9fbb39d7f9e0a63c71fbc96237ace62fae0db6. Adding back object+pose bone selection support removes the need for this fix. --- source/blender/editors/space_view3d/view3d_select.c | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'source/blender/editors/space_view3d/view3d_select.c') diff --git a/source/blender/editors/space_view3d/view3d_select.c b/source/blender/editors/space_view3d/view3d_select.c index 1d8d0f61150..e39bd3f945f 100644 --- a/source/blender/editors/space_view3d/view3d_select.c +++ b/source/blender/editors/space_view3d/view3d_select.c @@ -72,7 +72,6 @@ #include "BKE_scene.h" #include "BKE_tracking.h" #include "BKE_workspace.h" -#include "BKE_modifier.h" #include "DEG_depsgraph.h" @@ -2150,12 +2149,6 @@ static bool ed_object_select_pick(bContext *C, /* In pose mode we don't want to mess with object selection. */ const bool is_pose_mode = (vc.obact && vc.obact->mode & OB_MODE_POSE); - /* Support changing pose objects when the a mesh uses multiple armatures. */ - Object *old_obpose = NULL; - if (vc.obact && vc.obact->mode & OB_MODE_WEIGHT_PAINT) { - old_obpose = BKE_object_pose_armature_get(vc.obact); - } - /* always start list from basact in wire mode */ startbase = FIRSTBASE(view_layer); if (oldbasact && oldbasact->next) { @@ -2382,17 +2375,6 @@ static bool ed_object_select_pick(bContext *C, object_deselect_all_except(view_layer, basact); ED_object_base_select(basact, BA_SELECT); } - else if (old_obpose && modifiers_usesArmatureObject(oldbasact->object, basact->object)) { - /* The user is in weight-paint mode with an armature selected, - * in this case the user is selecting a new armature which is - * also used by the mesh. In this case use selection to switch - * the pose object, keeping the weight paint object active. */ - Base *old_basepose = BKE_view_layer_base_find(view_layer, old_obpose); - if (old_basepose != NULL) { - ED_object_base_select(old_basepose, BA_DESELECT); - } - ED_object_base_select(basact, BA_SELECT); - } /* also prevent making it active on mouse selection */ else if (BASE_SELECTABLE(v3d, basact)) { if (extend) { -- cgit v1.2.3