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:
authorChris Want <cwant@ualberta.ca>2006-01-28 19:35:18 +0300
committerChris Want <cwant@ualberta.ca>2006-01-28 19:35:18 +0300
commitc8b48e70e626a351dc3d02122ea413d0046e98b7 (patch)
tree0b4777ce258d751f501ec7ce16c129f01f3d3307 /source/blender/src/toolbox.c
parent45c7b2c5c2bc20296a581e1b6a1cb3908f11732f (diff)
parentdb5f7bd8da580d05c31f6fa65bfea8042deac10e (diff)
Final merge of HEAD (bf-blender) into the orange branch.
Here are my notes on things to look out for as potential problem spots: source/blender/blenkernel/intern/displist.c: + is initfastshade(void) supposed to be empty? I had to make it empty to get the merged tree to compile. source/blender/python/api2_2x/Armature.c: + went with the version that had Armature_getLayers() source/blender/python/api2_2x/Object.c + went with the version of Object_getPose() from bf-blender. (#ifdef 0-ed the other version) source/blender/python/api2_2x/Pose.[ch] + had problems linking due to no Pose_Init() ... copied these two files straight from bf-blender. source/blender/src/drawview.c: + view3d_panel_properties() had things shifted a few things shifted a few pixels, otherwise, things were painless source/blender/src/splash.jpg.c: + went with bf-blender version (orange is dead) source/gameengine: + went with bf-blender version -- does not compile due to IMB_rect* stuff, Ton should look into this.
Diffstat (limited to 'source/blender/src/toolbox.c')
-rw-r--r--source/blender/src/toolbox.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/source/blender/src/toolbox.c b/source/blender/src/toolbox.c
index 5372bb292db..88ad8ae4e3e 100644
--- a/source/blender/src/toolbox.c
+++ b/source/blender/src/toolbox.c
@@ -1359,6 +1359,19 @@ int do_clever_numbuts(char *name, int tot, int winevent)
int a, sizex, sizey, x1, y2;
short mval[2], event;
+ /* Clear all events so tooltips work, this is not ideal and
+ only needed because calls from the menu still have some events
+ left over when do_clever_numbuts is called.
+ Calls from keyshortcuts do not have this problem.*/
+ ScrArea *sa;
+ BWinEvent temp_bevt;
+ for (sa= G.curscreen->areabase.first; sa; sa= sa->next) {
+ while( bwin_qread( sa->win, &temp_bevt ) ) {}
+ while( bwin_qread( sa->headwin, &temp_bevt ) ) {}
+ }
+ /* Done clearing events */
+
+
if(tot<=0 || tot>MAXNUMBUTS) return 0;
getmouseco_sc(mval);
@@ -1383,6 +1396,9 @@ int do_clever_numbuts(char *name, int tot, int winevent)
/* WATCH IT: TEX BUTTON EXCEPTION */
/* WARNING: ONLY A SINGLE BIT-BUTTON POSSIBLE: WE WORK AT COPIED DATA! */
+
+ BIF_ThemeColor(TH_MENU_TEXT); /* makes text readable on dark theme */
+
uiDefBut(block, LABEL, 0, name, (short)(x1+15), (short)(y2-35), (short)(sizex-60), 19, 0, 1.0, 0.0, 0, 0, "");
/*
@@ -1394,12 +1410,22 @@ int do_clever_numbuts(char *name, int tot, int winevent)
uiBlockBeginAlign(block);
varstr= &numbuts[0];
for(a=0; a<tot; a++, varstr++) {
+
if(varstr->type==TEX) {
uiDefBut(block, TEX, 0, varstr->name,(short)(x1+15),(short)(y2-55-20*a),(short)(sizex-60), 19, numbpoin[a], varstr->min, varstr->max, 0, 0, varstr->tip);
}
else {
+
+ if(varstr->type==LABEL) /* dont include the label when rounding the buttons */
+ uiBlockEndAlign(block);
+
uiDefBut(block, varstr->type, 0, varstr->name,(short)(x1+15),(short)(y2-55-20*a), (short)(sizex-60), 19, &(numbdata[a]), varstr->min, varstr->max, 100, 0, varstr->tip);
+
+ if(varstr->type==LABEL)
+ uiBlockBeginAlign(block);
}
+
+
}
uiBlockEndAlign(block);