Action Editor:

Removed a little bit of old code I forgot to remove :)
This commit is contained in:
Joshua Leung 2007-06-20 07:33:25 +00:00
parent 0616766f87
commit d9b94275c0

@ -2696,8 +2696,8 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
{ {
extern void do_actionbuts(unsigned short event); // drawaction.c extern void do_actionbuts(unsigned short event); // drawaction.c
SpaceAction *saction; SpaceAction *saction;
bAction *act; void *data;
Key *key; short datatype;
float dx, dy; float dx, dy;
int doredraw= 0; int doredraw= 0;
int cfra; int cfra;
@ -2712,8 +2712,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
if (!saction) if (!saction)
return; return;
act=saction->action; data= get_action_context(&datatype);
key = get_action_mesh_key();
if (val) { if (val) {
if ( uiDoBlocks(&curarea->uiblocks, event)!=UI_NOTHING ) event= 0; if ( uiDoBlocks(&curarea->uiblocks, event)!=UI_NOTHING ) event= 0;
@ -2831,7 +2830,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
case MKEY: case MKEY:
if (G.qual & LR_SHIFTKEY) { if (G.qual & LR_SHIFTKEY) {
/* mirror keyframes */ /* mirror keyframes */
if (act || key) { if (data) {
val = pupmenu("Mirror Keys Over%t|Current Frame%x1|Vertical Axis%x2|Horizontal Axis %x3|Selected Marker %x4"); val = pupmenu("Mirror Keys Over%t|Current Frame%x1|Vertical Axis%x2|Horizontal Axis %x3|Selected Marker %x4");
mirror_action_keys(val); mirror_action_keys(val);
} }
@ -2881,7 +2880,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
case SKEY: case SKEY:
if (mval[0]>=ACTWIDTH) { if (mval[0]>=ACTWIDTH) {
if(G.qual & LR_SHIFTKEY) { if(G.qual & LR_SHIFTKEY) {
if (act || key) { if (data) {
val = pupmenu("Snap Keys To%t|Nearest Frame%x1|Current Frame%x2|Nearest Marker %x3"); val = pupmenu("Snap Keys To%t|Nearest Frame%x1|Current Frame%x2|Nearest Marker %x3");
snap_action_keys(val); snap_action_keys(val);
} }
@ -2904,7 +2903,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
break; break;
case PAGEUPKEY: case PAGEUPKEY:
if (act) { if (datatype == ACTCONT_ACTION) {
if(G.qual & LR_SHIFTKEY) if(G.qual & LR_SHIFTKEY)
top_sel_action(); top_sel_action();
else if (G.qual & LR_CTRLKEY) else if (G.qual & LR_CTRLKEY)
@ -2912,13 +2911,13 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
else else
nextprev_marker(1); nextprev_marker(1);
} }
else if (key) { else if (datatype == ACTCONT_SHAPEKEY) {
/* only jump to markers possible (key channels can't be moved yet) */ /* only jump to markers possible (key channels can't be moved yet) */
nextprev_marker(1); nextprev_marker(1);
} }
break; break;
case PAGEDOWNKEY: case PAGEDOWNKEY:
if (act) { if (datatype == ACTCONT_ACTION) {
if(G.qual & LR_SHIFTKEY) if(G.qual & LR_SHIFTKEY)
bottom_sel_action(); bottom_sel_action();
else if (G.qual & LR_CTRLKEY) else if (G.qual & LR_CTRLKEY)
@ -2926,7 +2925,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
else else
nextprev_marker(-1); nextprev_marker(-1);
} }
else if (key) { else if (datatype == ACTCONT_SHAPEKEY) {
/* only jump to markers possible (key channels can't be moved yet) */ /* only jump to markers possible (key channels can't be moved yet) */
nextprev_marker(-1); nextprev_marker(-1);
} }
@ -2980,7 +2979,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
case RIGHTMOUSE: case RIGHTMOUSE:
/* Clicking in the channel area */ /* Clicking in the channel area */
if (mval[0]<NAMEWIDTH) { if (mval[0]<NAMEWIDTH) {
if (act) { if (datatype == ACTCONT_ACTION) {
/* mouse is over action channels */ /* mouse is over action channels */
if (G.qual & LR_CTRLKEY) if (G.qual & LR_CTRLKEY)
clever_achannel_names(mval); clever_achannel_names(mval);