Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/object/object_constraint.c')
-rw-r--r--source/blender/editors/object/object_constraint.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/source/blender/editors/object/object_constraint.c b/source/blender/editors/object/object_constraint.c
index 450bd70a568..2055c906b41 100644
--- a/source/blender/editors/object/object_constraint.c
+++ b/source/blender/editors/object/object_constraint.c
@@ -567,7 +567,8 @@ static bConstraint *edit_constraint_property_get(wmOperator *op, Object *ob, int
}
con = constraints_findByName(list, constraint_name);
- printf("constraint found = %p, %s\n", (void *)con, (con)?con->name:"<Not found>");
+ //if (G.f & G_DEBUG)
+ //printf("constraint found = %p, %s\n", (void *)con, (con)?con->name:"<Not found>");
if (con && (type != 0) && (con->type != type))
con = NULL;
@@ -1114,14 +1115,19 @@ static int object_constraint_copy_exec(bContext *C, wmOperator *UNUSED(op))
CTX_DATA_BEGIN(C, Object*, ob, selected_editable_objects)
{
/* if we're not handling the object we're copying from, copy all constraints over */
- if (obact != ob)
+ if (obact != ob) {
copy_constraints(&ob->constraints, &obact->constraints, TRUE);
+ DAG_id_tag_update(&ob->id, OB_RECALC_DATA);
+ }
}
CTX_DATA_END;
/* force depsgraph to get recalculated since new relationships added */
DAG_scene_sort(bmain, scene); /* sort order of objects */
-
+
+ /* notifiers for updates */
+ WM_event_add_notifier(C, NC_OBJECT|ND_CONSTRAINT|NA_ADDED, NULL);
+
return OPERATOR_FINISHED;
}