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
This commit is contained in:
Philipp Oeser 2020-03-04 11:05:17 +01:00
parent a9dc1f6d00
commit 9c62a8c8e5
Notes: blender-bot 2023-05-29 09:17:12 +02:00
Referenced by issue #73797, Editing after Make Single User for Object Data
1 changed files with 3 additions and 0 deletions

View File

@ -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")) {