diff options
author | Joshua Leung <aligorith@gmail.com> | 2008-04-28 11:38:06 +0400 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2008-04-28 11:38:06 +0400 |
commit | 945527549024f7ba6a1cc185b30a103e293376ce (patch) | |
tree | fb09e12e4e612282a01eb65d84fe84329cba701a /source/blender/src/header_action.c | |
parent | cf84cf5f211475dc72cffe0ebba85e2ad91fee6b (diff) |
== Action Editor - Action Groups finishing touches ==
* Added a new tool "Synchronise with Armature" (found under Channels->Grouping), which synchronises the grouping of action-channels and the grouping of their relevant bones.
This only works when the active object is an armature, and the action isn't pinned. All of the action's action-channels are removed from their groups, and are added back into groups according to the current grouping of their corresponding bones.
A bit of testing for weird cases is needed.
* Group colours are now not drawn if the group originally was using the 'default' colour-set.
Diffstat (limited to 'source/blender/src/header_action.c')
-rw-r--r-- | source/blender/src/header_action.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/source/blender/src/header_action.c b/source/blender/src/header_action.c index 8405c5bf89d..503688aff69 100644 --- a/source/blender/src/header_action.c +++ b/source/blender/src/header_action.c @@ -136,7 +136,8 @@ enum { enum { ACTMENU_CHANNELS_GROUP_ADD_TOACTIVE = 0, ACTMENU_CHANNELS_GROUP_ADD_TONEW, - ACTMENU_CHANNELS_GROUP_REMOVE + ACTMENU_CHANNELS_GROUP_REMOVE, + ACTMENU_CHANNELS_GROUP_SYNCPOSE }; enum { @@ -762,6 +763,9 @@ static void do_action_channelmenu_groupmenu(void *arg, int event) case ACTMENU_CHANNELS_GROUP_REMOVE: action_groups_ungroup(); break; + case ACTMENU_CHANNELS_GROUP_SYNCPOSE: /* Syncronise Pose-data and Action-data */ + sync_pchan2achan_grouping(); + break; } } @@ -782,7 +786,7 @@ static uiBlock *action_channelmenu_groupmenu(void *arg_unused) "Add to New Group|Ctrl Shift G", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, ACTMENU_CHANNELS_GROUP_ADD_TONEW, ""); - + uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, ""); @@ -790,6 +794,14 @@ static uiBlock *action_channelmenu_groupmenu(void *arg_unused) "Remove From Group|Alt G", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, ACTMENU_CHANNELS_GROUP_REMOVE, ""); + + uiDefBut(block, SEPR, 0, "", 0, yco-=6, + menuwidth, 6, NULL, 0.0, 0.0, 0, 0, ""); + + uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, + "Synchronise with Armature", 0, yco-=20, + menuwidth, 19, NULL, 0.0, 0.0, 0, + ACTMENU_CHANNELS_GROUP_SYNCPOSE, ""); uiBlockSetDirection(block, UI_RIGHT); uiTextBoundsBlock(block, 60); |