Fix T91834: Appending objects with shape keys into new file is broken.

Recent append refactor 'broke' this, we need special recursive care and
handling of those nasty shpae keys... again.
This commit is contained in:
Bastien Montagne 2021-10-01 14:22:15 +02:00
parent f9acf21063
commit 271210126e
Notes: blender-bot 2023-02-14 09:24:53 +01:00
Referenced by issue #96048, Crash on appending with driver variables loop
Referenced by issue #92430, Appending File Causes Blender To Crash (NSFW)
Referenced by issue #91834, Appending objects with shape keys into new file is broken.
Referenced by issue #91689, shape keys animation lost when append
Referenced by issue #91689, shape keys animation lost when append
1 changed files with 5 additions and 0 deletions

View File

@ -597,6 +597,11 @@ static int foreach_libblock_append_callback(LibraryIDLinkCallbackData *cb_data)
}
if (!BKE_idtype_idcode_is_linkable(GS(id->name))) {
/* While we do not want to add non-linkable ID (shape keys...) to the list of linked items,
* unfortunately they can use fully linkable valid IDs too, like actions. Those need to be
* processed, so we need to recursively deal with them here. */
BKE_library_foreach_ID_link(
cb_data->bmain, id, foreach_libblock_append_callback, data, IDWALK_NOP);
return IDWALK_RET_NOP;
}