[Bf-blender-cvs] [08875452b0b] blender2.8: Base: update createTransObject

Dalai Felinto noreply at git.blender.org
Wed Mar 29 22:37:39 CEST 2017


Commit: 08875452b0b7ccde56e94e68bebdf511f2cd7c22
Author: Dalai Felinto
Date:   Wed Mar 29 22:08:51 2017 +0200
Branches: blender2.8
https://developer.blender.org/rB08875452b0b7ccde56e94e68bebdf511f2cd7c22

Base: update createTransObject

I was hoping this would fix the issue of the object not moving after you copy it (right now you need to manually grab the object afterwards). But unfortunatelly it does not

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

M	source/blender/editors/transform/transform_conversions.c

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

diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c
index 97221f588bb..550f80e284c 100644
--- a/source/blender/editors/transform/transform_conversions.c
+++ b/source/blender/editors/transform/transform_conversions.c
@@ -6467,8 +6467,6 @@ int special_transform_moving(TransInfo *t)
 
 static void createTransObject(bContext *C, TransInfo *t)
 {
-	Scene *scene = t->scene;
-
 	TransData *td = NULL;
 	TransDataExtension *tx;
 	const bool is_prop_edit = (t->flag & T_PROP_EDIT) != 0;
@@ -6518,15 +6516,16 @@ static void createTransObject(bContext *C, TransInfo *t)
 	CTX_DATA_END;
 	
 	if (is_prop_edit) {
-		View3D *v3d = t->view;
-		BaseLegacy *base;
+		SceneLayer *sl = t->sl;
+		Base *base;
 
-		for (base = scene->base.first; base; base = base->next) {
+		for (base = sl->object_bases.first; base; base = base->next) {
 			Object *ob = base->object;
 
 			/* if base is not selected, not a parent of selection or not a child of selection and it is editable */
-			if ((ob->flag & (SELECT | BA_TRANSFORM_CHILD | BA_TRANSFORM_PARENT)) == 0 &&
-			    BASE_EDITABLE_BGMODE(v3d, scene, base))
+			if ((ob->flag & (BA_TRANSFORM_CHILD | BA_TRANSFORM_PARENT)) == 0 &&
+			    (base->flag & BASE_SELECTED) == 0 &&
+			    BASE_EDITABLE_BGMODE_NEW(base))
 			{
 				td->protectflag = ob->protectflag;
 				td->ext = tx;




More information about the Bf-blender-cvs mailing list