diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-04-11 05:47:07 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-04-11 05:47:07 +0400 |
commit | 3216e4b202195ed88455d1b43b348a2cf8f40d77 (patch) | |
tree | 48b91e2916e48c74cc780f4ef2df538949bccf31 /source/blender/makesrna/intern | |
parent | a15b3c4d111613993eca23d5f99600c2052469e7 (diff) |
API Cleanup: Use BKE_constraint prefix for constraint api
Diffstat (limited to 'source/blender/makesrna/intern')
-rw-r--r-- | source/blender/makesrna/intern/rna_constraint.c | 4 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_object.c | 10 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_pose.c | 10 |
3 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/makesrna/intern/rna_constraint.c b/source/blender/makesrna/intern/rna_constraint.c index 6d6ea80fec8..1a18a1d8a31 100644 --- a/source/blender/makesrna/intern/rna_constraint.c +++ b/source/blender/makesrna/intern/rna_constraint.c @@ -237,7 +237,7 @@ static void rna_Constraint_name_set(PointerRNA *ptr, const char *value) /* if we have the list, check for unique name, otherwise give up */ if (list) - BKE_unique_constraint_name(con, list); + BKE_constraint_unique_name(con, list); } /* fix all the animation data which may link to this */ @@ -323,7 +323,7 @@ static EnumPropertyItem *rna_Constraint_target_space_itemf(bContext *UNUSED(C), PropertyRNA *UNUSED(prop), bool *UNUSED(r_free)) { bConstraint *con = (bConstraint *)ptr->data; - bConstraintTypeInfo *cti = BKE_constraint_get_typeinfo(con); + bConstraintTypeInfo *cti = BKE_constraint_typeinfo_get(con); ListBase targets = {NULL, NULL}; bConstraintTarget *ct; diff --git a/source/blender/makesrna/intern/rna_object.c b/source/blender/makesrna/intern/rna_object.c index 4a862928838..4a817806b89 100644 --- a/source/blender/makesrna/intern/rna_object.c +++ b/source/blender/makesrna/intern/rna_object.c @@ -1284,20 +1284,20 @@ static PointerRNA rna_Object_collision_get(PointerRNA *ptr) static PointerRNA rna_Object_active_constraint_get(PointerRNA *ptr) { Object *ob = (Object *)ptr->id.data; - bConstraint *con = BKE_constraints_get_active(&ob->constraints); + bConstraint *con = BKE_constraints_active_get(&ob->constraints); return rna_pointer_inherit_refine(ptr, &RNA_Constraint, con); } static void rna_Object_active_constraint_set(PointerRNA *ptr, PointerRNA value) { Object *ob = (Object *)ptr->id.data; - BKE_constraints_set_active(&ob->constraints, (bConstraint *)value.data); + BKE_constraints_active_set(&ob->constraints, (bConstraint *)value.data); } static bConstraint *rna_Object_constraints_new(Object *object, int type) { WM_main_add_notifier(NC_OBJECT | ND_CONSTRAINT | NA_ADDED, object); - return BKE_add_ob_constraint(object, NULL, type); + return BKE_constraint_add_for_object(object, NULL, type); } static void rna_Object_constraints_remove(Object *object, ReportList *reports, PointerRNA *con_ptr) @@ -1308,7 +1308,7 @@ static void rna_Object_constraints_remove(Object *object, ReportList *reports, P return; } - BKE_remove_constraint(&object->constraints, con); + BKE_constraint_remove(&object->constraints, con); RNA_POINTER_INVALIDATE(con_ptr); ED_object_constraint_update(object); @@ -1318,7 +1318,7 @@ static void rna_Object_constraints_remove(Object *object, ReportList *reports, P static void rna_Object_constraints_clear(Object *object) { - BKE_free_constraints(&object->constraints); + BKE_constraints_free(&object->constraints); ED_object_constraint_update(object); ED_object_constraint_set_active(object, NULL); diff --git a/source/blender/makesrna/intern/rna_pose.c b/source/blender/makesrna/intern/rna_pose.c index a7be3daea20..18e4ac6b004 100644 --- a/source/blender/makesrna/intern/rna_pose.c +++ b/source/blender/makesrna/intern/rna_pose.c @@ -481,14 +481,14 @@ static void rna_pose_pgroup_name_set(PointerRNA *ptr, const char *value, char *r static PointerRNA rna_PoseChannel_active_constraint_get(PointerRNA *ptr) { bPoseChannel *pchan = (bPoseChannel *)ptr->data; - bConstraint *con = BKE_constraints_get_active(&pchan->constraints); + bConstraint *con = BKE_constraints_active_get(&pchan->constraints); return rna_pointer_inherit_refine(ptr, &RNA_Constraint, con); } static void rna_PoseChannel_active_constraint_set(PointerRNA *ptr, PointerRNA value) { bPoseChannel *pchan = (bPoseChannel *)ptr->data; - BKE_constraints_set_active(&pchan->constraints, (bConstraint *)value.data); + BKE_constraints_active_set(&pchan->constraints, (bConstraint *)value.data); } static bConstraint *rna_PoseChannel_constraints_new(bPoseChannel *pchan, int type) @@ -496,7 +496,7 @@ static bConstraint *rna_PoseChannel_constraints_new(bPoseChannel *pchan, int typ /*WM_main_add_notifier(NC_OBJECT|ND_CONSTRAINT|NA_ADDED, object); */ /* TODO, pass object also */ /* TODO, new pose bones don't have updated draw flags */ - return BKE_add_pose_constraint(NULL, pchan, NULL, type); + return BKE_constraint_add_for_pose(NULL, pchan, NULL, type); } static void rna_PoseChannel_constraints_remove(ID *id, bPoseChannel *pchan, ReportList *reports, PointerRNA *con_ptr) @@ -510,12 +510,12 @@ static void rna_PoseChannel_constraints_remove(ID *id, bPoseChannel *pchan, Repo return; } - BKE_remove_constraint(&pchan->constraints, con); + BKE_constraint_remove(&pchan->constraints, con); RNA_POINTER_INVALIDATE(con_ptr); ED_object_constraint_update(ob); - BKE_constraints_set_active(&pchan->constraints, NULL); /* XXX, is this really needed? - Campbell */ + BKE_constraints_active_set(&pchan->constraints, NULL); /* XXX, is this really needed? - Campbell */ WM_main_add_notifier(NC_OBJECT | ND_CONSTRAINT | NA_REMOVED, id); |