[Bf-blender-cvs] [9624df5d1ed] master: Fix T63004: Make Links operator would still allow collection instancing for objects other than Empties

Philipp Oeser noreply at git.blender.org
Wed Mar 27 15:28:40 CET 2019


Commit: 9624df5d1edd74b1be77cf000dbd39f9e19f89c3
Author: Philipp Oeser
Date:   Wed Mar 27 14:57:13 2019 +0100
Branches: master
https://developer.blender.org/rB9624df5d1edd74b1be77cf000dbd39f9e19f89c3

Fix T63004: Make Links operator would still allow collection instancing
for objects other than Empties

In 2.8 support for dupli-group instancing for non-empty objects was
removed (rB2eca054e14b1), so better prevent operators from setting
this...

Reviewers: brecht

Maniphest Tasks: T63004

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

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

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 1f89da51d17..dbee2e77cf5 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -1361,9 +1361,13 @@ static bool allow_make_links_data(const int type, Object *ob_src, Object *ob_dst
 				return true;
 			}
 			break;
+		case MAKE_LINKS_DUPLICOLLECTION:
+			if (ob_dst->type == OB_EMPTY) {
+				return true;
+			}
+			break;
 		case MAKE_LINKS_ANIMDATA:
 		case MAKE_LINKS_GROUP:
-		case MAKE_LINKS_DUPLICOLLECTION:
 			return true;
 		case MAKE_LINKS_MODIFIERS:
 			if (!ELEM(OB_EMPTY, ob_src->type, ob_dst->type)) {



More information about the Bf-blender-cvs mailing list