Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Ebb <matt@mke3.net>2004-06-03 18:29:14 +0400
committerMatt Ebb <matt@mke3.net>2004-06-03 18:29:14 +0400
commit5926231d1287feab952fed91e858ee871c2b79e6 (patch)
tree10feb3f68d2f3c51722e89fcd1e57e1478c0573a /source/blender/src/header_oops.c
parent94042b0fef154aeac5571134099163776054c4e4 (diff)
* Added 'Transform' menus to Ipo, OOPS, Action, NLA, and
Sequence spaces * And a few small tweaks
Diffstat (limited to 'source/blender/src/header_oops.c')
-rw-r--r--source/blender/src/header_oops.c41
1 files changed, 41 insertions, 0 deletions
diff --git a/source/blender/src/header_oops.c b/source/blender/src/header_oops.c
index 8729af904f8..84a1d1008ab 100644
--- a/source/blender/src/header_oops.c
+++ b/source/blender/src/header_oops.c
@@ -206,6 +206,43 @@ static uiBlock *oops_selectmenu(void *arg_unused)
return block;
}
+static void do_oops_blockmenu(void *arg, int event)
+{
+ switch(event)
+ {
+ case 0: /* grab/move */
+ transform_oops('g');
+ break;
+ case 1: /* scale */
+ transform_oops('s');
+ break;
+ }
+}
+
+static uiBlock *oops_blockmenu(void *arg_unused)
+{
+ uiBlock *block;
+ short yco= 0, menuwidth=120;
+
+ block= uiNewBlock(&curarea->uiblocks, "oops_blockmenu", UI_EMBOSSP, UI_HELV, curarea->headwin);
+ uiBlockSetButmFunc(block, do_oops_blockmenu, NULL);
+
+ uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Grab/Move|G", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Scale|S", 0, yco-=20, menuwidth, 19, NULL, 0.0, 0.0, 0, 1, "");
+
+ if(curarea->headertype==HEADERTOP) {
+ uiBlockSetDirection(block, UI_DOWN);
+ }
+ else {
+ uiBlockSetDirection(block, UI_TOP);
+ uiBlockFlipOrder(block);
+ }
+
+ uiTextBoundsBlock(block, 50);
+
+ return block;
+}
+
void oops_buttons(void)
{
@@ -255,6 +292,10 @@ void oops_buttons(void)
xmax= GetButStringLength("Select");
uiDefBlockBut(block, oops_selectmenu, NULL, "Select", xco, -2, xmax-3, 24, "");
xco+= xmax;
+
+ xmax= GetButStringLength("Block");
+ uiDefBlockBut(block, oops_blockmenu, NULL, "Block", xco, -2, xmax-3, 24, "");
+ xco+= xmax;
}