diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2016-07-11 20:39:34 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2016-07-11 22:30:02 +0300 |
commit | 13f0b59f1180042b07f439d36841a52a6ddcd75e (patch) | |
tree | 29c32ac5edaaf896d6f9d4ff29ecb81a1654feaa /source/blender/blenkernel/intern/action.c | |
parent | 2ec17e655c4fdabc6251b5c81f4404451160923c (diff) |
Use new generic BKE_id_expand_local() for both make_local() and copy() functions of actions, brushes and particles.
This greatly simplifies said code, once again no change expected from user PoV.
Diffstat (limited to 'source/blender/blenkernel/intern/action.c')
-rw-r--r-- | source/blender/blenkernel/intern/action.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/action.c b/source/blender/blenkernel/intern/action.c index aa733e8d90e..5712026a554 100644 --- a/source/blender/blenkernel/intern/action.c +++ b/source/blender/blenkernel/intern/action.c @@ -113,6 +113,7 @@ void BKE_action_make_local(Main *bmain, bAction *act) if (is_local) { if (!is_lib) { id_clear_lib_data(bmain, &act->id); + BKE_id_expand_local(&act->id, false); } else { bAction *act_new = BKE_action_copy(bmain, act); @@ -183,6 +184,8 @@ bAction *BKE_action_copy(Main *bmain, bAction *src) } } + BKE_id_expand_local(&dst->id, true); + if (ID_IS_LINKED_DATABLOCK(src)) { BKE_id_lib_local_paths(bmain, src->id.lib, &dst->id); } |