diff options
author | Ton Roosendaal <ton@blender.org> | 2005-11-02 01:48:07 +0300 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2005-11-02 01:48:07 +0300 |
commit | 48dbe3a5fc068b0f39f290230e5f4d7d5c46af1f (patch) | |
tree | 2e9545e395e880dfcd1578e716745ddb0d6a1553 /source/blender/src/transform_conversions.c | |
parent | 893cf26e93c75bc10619ad1bb38be55d7762dac9 (diff) |
#3308
Autokey didn't work for Object actions yet.
Diffstat (limited to 'source/blender/src/transform_conversions.c')
-rwxr-xr-x | source/blender/src/transform_conversions.c | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/source/blender/src/transform_conversions.c b/source/blender/src/transform_conversions.c index 23c55073b7b..8edbbfaf802 100755 --- a/source/blender/src/transform_conversions.c +++ b/source/blender/src/transform_conversions.c @@ -2090,18 +2090,22 @@ void special_aftertrans_update(TransInfo *t) /* Set autokey if necessary */ if ((G.flags & G_RECORDKEYS) && (!cancelled) && (base->flag & SELECT)){ - /* note, here we have to do context still */ - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_ROT_X); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_ROT_Y); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_ROT_Z); + char *actname=""; + + if(ob->ipoflag & OB_ACTION_OB) + actname= "Object"; + + insertkey(&base->object->id, ID_OB, actname, NULL, OB_ROT_X); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_ROT_Y); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_ROT_Z); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_LOC_X); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_LOC_Y); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_LOC_Z); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_LOC_X); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_LOC_Y); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_LOC_Z); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_SIZE_X); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_SIZE_Y); - insertkey(&base->object->id, ID_OB, NULL, NULL, OB_SIZE_Z); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_SIZE_X); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_SIZE_Y); + insertkey(&base->object->id, ID_OB, actname, NULL, OB_SIZE_Z); remake_object_ipos (ob); allqueue(REDRAWIPO, 0); |