diff options
author | Johnny Matthews <johnny.matthews@gmail.com> | 2004-04-20 08:59:04 +0400 |
---|---|---|
committer | Johnny Matthews <johnny.matthews@gmail.com> | 2004-04-20 08:59:04 +0400 |
commit | ccad67c92c0a1d0d329efbe8405cfa88c0ef4185 (patch) | |
tree | 34ff322481f2e57811da31082b346f06d75ad321 /source/blender/src/header_ipo.c | |
parent | dfc824a13457c724b6e86606c4586036bc39cf71 (diff) |
Adds a 'Edit Selected' to the curve menu in the IPO window. So that the curve editmode can be entered with a menu selection as well as TAB. Previously, there was no reference to the curve editmode in the IPO window.
When one or more curves is being edited,there is a checkmark by the menu option and you can slect it again to leave editmode.
This commit is more for people learning Blender as people who know will just press TAB.
Diffstat (limited to 'source/blender/src/header_ipo.c')
-rw-r--r-- | source/blender/src/header_ipo.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/source/blender/src/header_ipo.c b/source/blender/src/header_ipo.c index 3614223b48f..1bce54c4065 100644 --- a/source/blender/src/header_ipo.c +++ b/source/blender/src/header_ipo.c @@ -349,6 +349,9 @@ static void do_ipo_editmenu(void *arg, int event) case 5: //join_ipo(); break; + case 6: + /*IPO Editmode*/ + set_editflag_editipo(); } } @@ -357,6 +360,7 @@ static uiBlock *ipo_editmenu(void *arg_unused) uiBlock *block; EditIpo *ei; short yco= 0, menuwidth=120; + int a,isedit = 0; get_status_editipo(); @@ -367,7 +371,26 @@ static uiBlock *ipo_editmenu(void *arg_unused) uiDefIconTextBut(block, BUTM, 1, ICON_MENU_PANEL, "Transform Properties|N", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 4, ""); uiDefIconTextBlockBut(block, ipo_editmenu_snapmenu, NULL, ICON_RIGHTARROW_THIN, "Snap", 0, yco-=20, 120, 19, ""); + + uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, ""); + + /*Look to see if any ipos are being edited, so there can be a check next to the menu option*/ + for(a=0; a<G.sipo->totipo; a++, ei++) { + if(ei->icu) { + if(ei->flag & IPO_VISIBLE) { + if(totipo_edit && (ei->flag & IPO_EDIT)) { + isedit = 1; + break; + } + } + } + } + if(isedit) + uiDefIconTextBut(block, BUTM, 1, ICON_CHECKBOX_HLT, "Edit Selected|TAB", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 6, ""); + else + uiDefIconTextBut(block, BUTM, 1, ICON_CHECKBOX_DEHLT, "Edit Selected|TAB", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 6, ""); + ei = G.sipo->editipo; uiDefBut(block, SEPR, 0, "", 0, yco-=6, menuwidth, 6, NULL, 0.0, 0.0, 0, 0, ""); uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Insert Keyframe...|I", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 3, ""); |