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
path: root/source
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2005-10-03 23:30:50 +0400
committerTon Roosendaal <ton@blender.org>2005-10-03 23:30:50 +0400
commitc7f4016349a93624542cf9179102ebcfe350ad19 (patch)
tree8ab1d061c52bae118af47fc0eef8b6dc19d41944 /source
parent080b7f09022f2407eab861e239bc32ef23a15a14 (diff)
Commit I did sept 22 gave returnvalues to buttons, but that should not be
on buttons in popup menus (like postproduction settings etc) Error was that the menu returned immediate now.
Diffstat (limited to 'source')
-rw-r--r--source/blender/src/buttons_scene.c40
1 files changed, 21 insertions, 19 deletions
diff --git a/source/blender/src/buttons_scene.c b/source/blender/src/buttons_scene.c
index 5fcac9a8810..01628cfeb1d 100644
--- a/source/blender/src/buttons_scene.c
+++ b/source/blender/src/buttons_scene.c
@@ -782,6 +782,7 @@ void do_render_panels(unsigned short event)
}
}
+/* NOTE: this is a block-menu, needs 0 events, otherwise the menu closes */
static uiBlock *edge_render_menu(void *arg_unused)
{
uiBlock *block;
@@ -792,9 +793,9 @@ static uiBlock *edge_render_menu(void *arg_unused)
uiDefBut(block, LABEL, 0, "", 290, -15, 220, 115, NULL, 0, 0, 0, 0, "");
uiBlockBeginAlign(block);
- uiDefButS(block, NUM, B_NOP,"Eint:", 370,75,135,19, &G.scene->r.edgeint, 0.0, 255.0, 0, 0,
+ uiDefButS(block, NUM, 0,"Eint:", 370,75,135,19, &G.scene->r.edgeint, 0.0, 255.0, 0, 0,
"Sets edge intensity for Toon shading");
- uiDefButS(block, NUM, B_NOP,"AntiShift",370,55,135,19, &(G.scene->r.same_mat_redux), 0, 255.0, 0, 0,
+ uiDefButS(block, NUM, 0,"AntiShift",370,55,135,19, &(G.scene->r.same_mat_redux), 0, 255.0, 0, 0,
"For unified renderer: reduce intensity on boundaries "
"with identical materials with this number.");
@@ -809,11 +810,11 @@ static uiBlock *edge_render_menu(void *arg_unused)
uiDefButF(block, COL, 0, "", 295,-10,30,60, &(G.scene->r.edgeR), 0, 0, 0, B_EDGECOLSLI, "");
uiBlockBeginAlign(block);
- uiDefButF(block, NUMSLI, B_NOP, "R ", 330, 30, 175,19, &G.scene->r.edgeR, 0.0, 1.0, B_EDGECOLSLI, 0,
+ uiDefButF(block, NUMSLI, 0, "R ", 330, 30, 175,19, &G.scene->r.edgeR, 0.0, 1.0, B_EDGECOLSLI, 0,
"For unified renderer: Colour for edges in toon shading mode.");
- uiDefButF(block, NUMSLI, B_NOP, "G ", 330, 10, 175,19, &G.scene->r.edgeG, 0.0, 1.0, B_EDGECOLSLI, 0,
+ uiDefButF(block, NUMSLI, 0, "G ", 330, 10, 175,19, &G.scene->r.edgeG, 0.0, 1.0, B_EDGECOLSLI, 0,
"For unified renderer: Colour for edges in toon shading mode.");
- uiDefButF(block, NUMSLI, B_NOP, "B ", 330, -10, 175,19, &G.scene->r.edgeB, 0.0, 1.0, B_EDGECOLSLI, 0,
+ uiDefButF(block, NUMSLI, 0, "B ", 330, -10, 175,19, &G.scene->r.edgeB, 0.0, 1.0, B_EDGECOLSLI, 0,
"For unified renderer: Colour for edges in toon shading mode.");
@@ -822,6 +823,7 @@ static uiBlock *edge_render_menu(void *arg_unused)
return block;
}
+/* NOTE: this is a block-menu, needs 0 events, otherwise the menu closes */
static uiBlock *post_render_menu(void *arg_unused)
{
uiBlock *block;
@@ -831,11 +833,11 @@ static uiBlock *post_render_menu(void *arg_unused)
/* use this for a fake extra empy space around the buttons */
uiDefBut(block, LABEL, 0, "", -10, -10, 200, 120, NULL, 0, 0, 0, 0, "");
uiBlockBeginAlign(block);
- uiDefButF(block, NUMSLI, B_NOP, "Add:", 0,80,180,19, &G.scene->r.postadd, -1.0, 1.0, 0, 0, "");
- uiDefButF(block, NUMSLI, B_NOP, "Mul:", 0,60,180,19, &G.scene->r.postmul, 0.01, 4.0, 0, 0, "");
- uiDefButF(block, NUMSLI, B_NOP, "Gamma:", 0,40,180,19, &G.scene->r.postgamma, 0.1, 4.0, 0, 0, "");
- uiDefButF(block, NUMSLI, B_NOP, "Hue:", 0,20,180,19, &G.scene->r.posthue, -0.5, 0.5, 0, 0, "");
- uiDefButF(block, NUMSLI, B_NOP, "Sat:", 0, 0,180,19, &G.scene->r.postsat, 0.0, 4.0, 0, 0, "");
+ uiDefButF(block, NUMSLI, 0, "Add:", 0,80,180,19, &G.scene->r.postadd, -1.0, 1.0, 0, 0, "");
+ uiDefButF(block, NUMSLI, 0, "Mul:", 0,60,180,19, &G.scene->r.postmul, 0.01, 4.0, 0, 0, "");
+ uiDefButF(block, NUMSLI, 0, "Gamma:", 0,40,180,19, &G.scene->r.postgamma, 0.1, 4.0, 0, 0, "");
+ uiDefButF(block, NUMSLI, 0, "Hue:", 0,20,180,19, &G.scene->r.posthue, -0.5, 0.5, 0, 0, "");
+ uiDefButF(block, NUMSLI, 0, "Sat:", 0, 0,180,19, &G.scene->r.postsat, 0.0, 4.0, 0, 0, "");
uiBlockSetDirection(block, UI_TOP);
@@ -844,7 +846,7 @@ static uiBlock *post_render_menu(void *arg_unused)
return block;
}
-
+/* NOTE: this is a block-menu, needs 0 events, otherwise the menu closes */
static uiBlock *framing_render_menu(void *arg_unused)
{
uiBlock *block;
@@ -856,7 +858,7 @@ static uiBlock *framing_render_menu(void *arg_unused)
/* use this for a fake extra empy space around the buttons */
uiDefBut(block, LABEL, 0, "", -5, -10, 295, 224, NULL, 0, 0, 0, 0, "");
- uiDefBut(block, LABEL, B_NOP, "Framing:", xco, yco, 68,19, 0, 0, 0, 0, 0, "");
+ uiDefBut(block, LABEL, 0, "Framing:", xco, yco, 68,19, 0, 0, 0, 0, 0, "");
uiBlockBeginAlign(block);
uiDefButC(block, ROW, 0, "Stretch", xco += 70, yco, 68, 19, &G.scene->framing.type, 1.0, SCE_GAMEFRAMING_SCALE , 0, 0, "Stretch or squeeze the viewport to fill the display window");
uiDefButC(block, ROW, 0, "Expose", xco += 70, yco, 68, 19, &G.scene->framing.type, 1.0, SCE_GAMEFRAMING_EXTEND, 0, 0, "Show the entire viewport in the display window, viewing more horizontally or vertically");
@@ -869,21 +871,21 @@ static uiBlock *framing_render_menu(void *arg_unused)
uiDefButF(block, COL, 0, "", 0, yco - 58 + 18, 33, 58, &G.scene->framing.col[0], 0, 0, 0, randomcolorindex, "");
uiBlockBeginAlign(block);
- uiDefButF(block, NUMSLI, B_NOP, "R ", xco,yco,243,18, &G.scene->framing.col[0], 0.0, 1.0, randomcolorindex, 0, "Set the red component of the bars");
+ uiDefButF(block, NUMSLI, 0, "R ", xco,yco,243,18, &G.scene->framing.col[0], 0.0, 1.0, randomcolorindex, 0, "Set the red component of the bars");
yco -= 20;
- uiDefButF(block, NUMSLI, B_NOP, "G ", xco,yco,243,18, &G.scene->framing.col[1], 0.0, 1.0, randomcolorindex, 0, "Set the green component of the bars");
+ uiDefButF(block, NUMSLI, 0, "G ", xco,yco,243,18, &G.scene->framing.col[1], 0.0, 1.0, randomcolorindex, 0, "Set the green component of the bars");
yco -= 20;
- uiDefButF(block, NUMSLI, B_NOP, "B ", xco,yco,243,18, &G.scene->framing.col[2], 0.0, 1.0, randomcolorindex, 0, "Set the blue component of the bars");
+ uiDefButF(block, NUMSLI, 0, "B ", xco,yco,243,18, &G.scene->framing.col[2], 0.0, 1.0, randomcolorindex, 0, "Set the blue component of the bars");
uiBlockEndAlign(block);
xco = 0;
uiDefBut(block, LABEL, 0, "Fullscreen:", xco, yco-=30, 100, 19, 0, 0.0, 0.0, 0, 0, "");
uiDefButS(block, TOG, 0, "Fullscreen", xco+70, yco, 68, 19, &G.scene->r.fullscreen, 0.0, 0.0, 0, 0, "Starts player in a new fullscreen display");
uiBlockBeginAlign(block);
- uiDefButS(block, NUM, B_NOP, "X:", xco+40, yco-=27, 100, 19, &G.scene->r.xplay, 10.0, 2000.0, 0, 0, "Displays current X screen/window resolution. Click to change.");
- uiDefButS(block, NUM, B_NOP, "Y:", xco+140, yco, 100, 19, &G.scene->r.yplay, 10.0, 2000.0, 0, 0, "Displays current Y screen/window resolution. Click to change.");
- uiDefButS(block, NUM, B_NOP, "Freq:", xco+40, yco-=21, 100, 19, &G.scene->r.freqplay, 10.0, 2000.0, 0, 0, "Displays clock frequency of fullscreen display. Click to change.");
- uiDefButS(block, NUM, B_NOP, "Bits:", xco+140, yco, 100, 19, &G.scene->r.depth, 8.0, 32.0, 800.0, 0, "Displays bit depth of full screen display. Click to change.");
+ uiDefButS(block, NUM, 0, "X:", xco+40, yco-=27, 100, 19, &G.scene->r.xplay, 10.0, 2000.0, 0, 0, "Displays current X screen/window resolution. Click to change.");
+ uiDefButS(block, NUM, 0, "Y:", xco+140, yco, 100, 19, &G.scene->r.yplay, 10.0, 2000.0, 0, 0, "Displays current Y screen/window resolution. Click to change.");
+ uiDefButS(block, NUM, 0, "Freq:", xco+40, yco-=21, 100, 19, &G.scene->r.freqplay, 10.0, 2000.0, 0, 0, "Displays clock frequency of fullscreen display. Click to change.");
+ uiDefButS(block, NUM, 0, "Bits:", xco+140, yco, 100, 19, &G.scene->r.depth, 8.0, 32.0, 800.0, 0, "Displays bit depth of full screen display. Click to change.");
uiBlockEndAlign(block);
/* stereo settings */