[Bf-blender-cvs] [9c62a8c8e53] master: Fix T73797: Selection/Editing after Make Single User for Object Data fails

Philipp Oeser noreply at git.blender.org
Wed Mar 4 11:31:50 CET 2020


Commit: 9c62a8c8e53fbcd14100153b0abc659771b1f551
Author: Philipp Oeser
Date:   Wed Mar 4 11:05:17 2020 +0100
Branches: master
https://developer.blender.org/rB9c62a8c8e53fbcd14100153b0abc659771b1f551

Fix T73797: Selection/Editing after Make Single User for Object Data
fails

Exposed by rB50d5c03e2d14.

This was only a problem when _only_ 'Object Data' was made local.
If also e.g. 'Object' or 'Materials' was checked, these were already
making sure realations were updated [DEG_relations_tag_update(bmain)].

Now also call DEG_relations_tag_update(bmain) for the 'Object Data'
case.

I assume the underlying issue is that there is some ID_NEW_REMAP
happening in 'single_obdata_users()' -- including that for 'me-
>texcomesh', which might be responsible for the glitches in selection/
editing? Also not entirely sure why this wasnt a problem prior to
rB50d5c03e2d14.(I assume this was somewhat hidden by the fact this was
always called with a default action being nothing, the user would always
need to access the redo panel. So this might have been hidden by an Undo
step involved?)

Maniphest Tasks: T73797

Differential Revision: https://developer.blender.org/D7020

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

M	source/blender/editors/object/object_relations.c

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

diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c
index b1e3e4b64f2..0ce2b21cbbd 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -2609,6 +2609,9 @@ static int make_single_user_exec(bContext *C, wmOperator *op)
 
   if (RNA_boolean_get(op->ptr, "obdata")) {
     single_obdata_users(bmain, scene, view_layer, v3d, flag);
+
+    /* Needed since some IDs were remapped? (incl. me->texcomesh, see T73797). */
+    update_deps = true;
   }
 
   if (RNA_boolean_get(op->ptr, "material")) {



More information about the Bf-blender-cvs mailing list