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:
Diffstat (limited to 'source/blender/src/interface.c')
-rw-r--r--source/blender/src/interface.c35
1 files changed, 20 insertions, 15 deletions
diff --git a/source/blender/src/interface.c b/source/blender/src/interface.c
index 78b94c42564..f7429c3bc57 100644
--- a/source/blender/src/interface.c
+++ b/source/blender/src/interface.c
@@ -1225,7 +1225,8 @@ static int ui_do_but_MENU(uiBut *but)
uibut_do_func(but);
- return event;
+ if(event == UI_NOTHING) return 0;
+ else return but->retval;
}
@@ -3749,27 +3750,31 @@ static void ui_do_but_tip(uiBut *buttip)
* as long as the mouse remains on top
* of the button that owns it.
*/
+ Mat4CpyMat4(UIwinmat, buttip->block->winmat); // get rid of uiwinmat once...
uiPanelPush(buttip->block); // panel matrix
od= ui_draw_but_tip(buttip);
- while (1) {
- char ascii;
- short val;
- unsigned short evt= extern_qread_ext(&val, &ascii);
-
- if (evt==MOUSEX || evt==MOUSEY) {
- short mouse[2];
- uiGetMouse(od->oldwin, mouse);
-
- if (!uibut_contains_pt(buttip, mouse))
+ if(od) {
+ while (1) {
+ char ascii;
+ short val;
+ unsigned short evt= extern_qread_ext(&val, &ascii);
+
+ if (evt==MOUSEX || evt==MOUSEY) {
+ short mouse[2];
+ uiGetMouse(od->oldwin, mouse);
+
+ if (!uibut_contains_pt(buttip, mouse))
+ break;
+ } else {
+ mainqpushback(evt, val, ascii);
break;
- } else {
- mainqpushback(evt, val, ascii);
- break;
+ }
}
+
+ ui_end_overdraw(od);
}
- ui_end_overdraw(od);
uiPanelPop(buttip->block); // panel matrix
/* still the evil global.... */
UIbuttip= NULL;