diff options
author | Joshua Leung <aligorith@gmail.com> | 2018-06-01 17:24:59 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2018-06-01 17:24:59 +0300 |
commit | a12ab5b2ef49ccacae091ccb54d72de0d63f990d (patch) | |
tree | c0e27dc580fca576dc7e3fc0ee21db2559d0f80c /source/blender/editors/object/object_relations.c | |
parent | e9e8f105d0311e61f99d8a8777ed77d38b49fe46 (diff) | |
parent | 44a8070db3c03a4e12d1ec1ca15432ec2b36e2fc (diff) |
Merge branch 'blender2.8' into tmp-b28-motionpath-drawingtmp-b28-motionpath-drawing
Diffstat (limited to 'source/blender/editors/object/object_relations.c')
-rw-r--r-- | source/blender/editors/object/object_relations.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c index aee8c3f9122..d417437ad99 100644 --- a/source/blender/editors/object/object_relations.c +++ b/source/blender/editors/object/object_relations.c @@ -2304,7 +2304,7 @@ static int make_override_static_exec(bContext *C, wmOperator *op) } FOREACH_COLLECTION_OBJECT_RECURSIVE_END; - /* Then, we make static override of the whole set of objects in the collection. */ + /* Then, we remove (untag) bone shape objects, you shall never want to override those (hopefully)... */ FOREACH_COLLECTION_OBJECT_RECURSIVE_BEGIN(collection, ob) { if (ob->type == OB_ARMATURE && ob->pose != NULL) { @@ -2325,18 +2325,16 @@ static int make_override_static_exec(bContext *C, wmOperator *op) Collection *new_collection = (Collection *)collection->id.newid; FOREACH_COLLECTION_OBJECT_RECURSIVE_BEGIN(new_collection, new_ob) { - if (new_ob != NULL && - new_ob->id.override_static != NULL && - (base = BKE_view_layer_base_find(view_layer, new_ob)) == NULL) - { - BKE_collection_object_add_from(bmain, scene, obcollection, new_ob); - DEG_id_tag_update_ex(bmain, &new_ob->id, OB_RECALC_OB | DEG_TAG_BASE_FLAGS_UPDATE); + if (new_ob != NULL && new_ob->id.override_static != NULL) { + if ((base = BKE_view_layer_base_find(view_layer, new_ob)) == NULL) { + BKE_collection_object_add_from(bmain, scene, obcollection, new_ob); + DEG_id_tag_update_ex(bmain, &new_ob->id, DEG_TAG_TRANSFORM | DEG_TAG_BASE_FLAGS_UPDATE); + } /* parent to 'collection' empty */ if (new_ob->parent == NULL) { new_ob->parent = obcollection; } if (new_ob == (Object *)obact->id.newid) { - base = BKE_view_layer_base_find(view_layer, new_ob); BKE_view_layer_base_select(view_layer, base); } else { |