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:
authorTon Roosendaal <ton@blender.org>2003-07-08 14:15:42 +0400
committerTon Roosendaal <ton@blender.org>2003-07-08 14:15:42 +0400
commite45e14545351040837f768bbb01a850a0e26454f (patch)
tree942cb2f08df5ee0538eb2da8e59e3d99758bb7f5
parentc5cc6a28a40643ac8725b04413ed42e0d75511d0 (diff)
* fixed two more subloops in button drawing for new optimized usage of
glFinish(). Textbut and the 'But' (render for example) didnt work proper.
-rw-r--r--source/blender/src/interface.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/blender/src/interface.c b/source/blender/src/interface.c
index 768a5e2b534..2993dc8c9f1 100644
--- a/source/blender/src/interface.c
+++ b/source/blender/src/interface.c
@@ -1983,10 +1983,12 @@ static int ui_do_but_BUT(uiBut *but)
else
but->flag &= ~UI_SELECT;
- if (but->flag != oflag)
+ if (but->flag != oflag) {
ui_draw_but(but);
-
- PIL_sleep_ms(1);
+ glFinish(); // flush display in subloops
+ }
+
+ PIL_sleep_ms(10);
} while (get_mbut() & L_MOUSE);
activated= (but->flag & UI_SELECT);
@@ -2150,7 +2152,8 @@ static int ui_do_but_TEX(uiBut *but)
BLI_strncpy(backstr, but->poin, UI_MAX_DRAW_STR);
ui_draw_but(but);
-
+ glFinish(); // flush display in subloops
+
while (get_mbut() & L_MOUSE) BIF_wait_for_statechange();
len= strlen(str);
but->min= 0.0;