forked from bartvdbraak/blender
Added missing menu entries for Preview Range tools
This commit is contained in:
parent
5ad6b3f8dd
commit
f190e4e0e2
@ -95,7 +95,10 @@ enum {
|
||||
ACTMENU_VIEW_NOHIDE,
|
||||
ACTMENU_VIEW_TRANSDELDUPS,
|
||||
ACTMENU_VIEW_HORIZOPTIMISE,
|
||||
ACTMENU_VIEW_GCOLORS
|
||||
ACTMENU_VIEW_GCOLORS,
|
||||
ACTMENU_VIEW_PREVRANGESET,
|
||||
ACTMENU_VIEW_PREVRANGECLEAR,
|
||||
ACTMENU_VIEW_PREVRANGEAUTO
|
||||
};
|
||||
|
||||
enum {
|
||||
@ -350,6 +353,15 @@ static void do_action_viewmenu(void *arg, int event)
|
||||
case ACTMENU_VIEW_GCOLORS: /* Draw grouped-action channels using its group's color */
|
||||
G.saction->flag ^= SACTION_NODRAWGCOLORS;
|
||||
break;
|
||||
case ACTMENU_VIEW_PREVRANGESET: /* Set preview range */
|
||||
anim_previewrange_set();
|
||||
break;
|
||||
case ACTMENU_VIEW_PREVRANGECLEAR: /* Clear preview range */
|
||||
anim_previewrange_clear();
|
||||
break;
|
||||
case ACTMENU_VIEW_PREVRANGEAUTO: /* Auto preview-range length */
|
||||
action_previewrange_set(G.saction->action);
|
||||
break;
|
||||
}
|
||||
allqueue(REDRAWVIEW3D, 0);
|
||||
}
|
||||
@ -447,11 +459,30 @@ static uiBlock *action_viewmenu(void *arg_unused)
|
||||
"Play Back Animation|Alt A", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1,
|
||||
ACTMENU_VIEW_PLAY3D, "");
|
||||
//uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1,
|
||||
// "Play Back Animation in 3D View|Alt Shift A", 0, yco-=20,
|
||||
// menuwidth, 19, NULL, 0.0, 0.0, 1,
|
||||
// ACTMENU_VIEW_PLAYALL, "");
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6,
|
||||
menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1,
|
||||
"Play Back Animation in 3D View|Alt Shift A", 0, yco-=20,
|
||||
"Set Preview Range|Ctrl P", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1,
|
||||
ACTMENU_VIEW_PLAYALL, "");
|
||||
|
||||
ACTMENU_VIEW_PREVRANGESET, "");
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1,
|
||||
"Clear Preview Range|Alt P", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1,
|
||||
ACTMENU_VIEW_PREVRANGECLEAR, "");
|
||||
|
||||
if (G.saction->action) {
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1,
|
||||
"Preview Range from Action Length|Ctrl Alt P", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1,
|
||||
ACTMENU_VIEW_PREVRANGEAUTO, "");
|
||||
}
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6,
|
||||
menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
|
@ -745,6 +745,12 @@ static void do_ipo_viewmenu(void *arg, int event)
|
||||
case 12:
|
||||
G.sipo->flag ^= SIPO_LOCK_VIEW;
|
||||
break;
|
||||
case 13: /* Set Preview Range */
|
||||
anim_previewrange_set();
|
||||
break;
|
||||
case 14: /* Clear Preview Range */
|
||||
anim_previewrange_clear();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@ -775,10 +781,17 @@ static uiBlock *ipo_viewmenu(void *arg_unused)
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Animation|Alt A", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1, 6, "");
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Animation in 3D View|Alt Shift A", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1, 7, "");
|
||||
//uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Animation in 3D View|Alt Shift A", 0, yco-=20,
|
||||
// menuwidth, 19, NULL, 0.0, 0.0, 1, 7, "");
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Set Preview Range|Ctrl P", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1, 13, "");
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Clear Preview Range|Alt P", 0, yco-=20,
|
||||
menuwidth, 19, NULL, 0.0, 0.0, 1, 14, "");
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Center on Current Frame|Shift C", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 10, "");
|
||||
|
@ -122,6 +122,12 @@ static void do_nla_viewmenu(void *arg, int event)
|
||||
case 7: /* Show timing in Frames or Seconds */
|
||||
G.snla->flag ^= SNLA_DRAWTIME;
|
||||
break;
|
||||
case 8: /* Set Preview Range */
|
||||
anim_previewrange_set();
|
||||
break;
|
||||
case 9: /* Clear Preview Range */
|
||||
anim_previewrange_clear();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@ -154,7 +160,12 @@ static uiBlock *nla_viewmenu(void *arg_unused)
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Back Animation|Alt A", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 1, 1, "");
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Back Animation in 3D View|Alt Shift A", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 1, 2, "");
|
||||
//uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Play Back Animation in 3D View|Alt Shift A", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 1, 2, "");
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Set Preview Range|Ctrl P", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 1, 8, "");
|
||||
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Clear Preview Range|Alt P", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 1, 9, "");
|
||||
|
||||
uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, "");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user