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:
authorCampbell Barton <ideasman42@gmail.com>2012-08-17 15:31:54 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-08-17 15:31:54 +0400
commitdac761057d16e264a74162ba625bdb3c6cf07fb4 (patch)
tree93f833942b7cb7ba01d125672c5689e47d3adf46 /source/blender
parent219fb7ad7908a2d3ddb8dfe77bd8e702202a7ff9 (diff)
fix for crash showing tooltip for NODE_OT_add_search()
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/interface/interface_intern.h2
-rw-r--r--source/blender/editors/interface/interface_regions.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h
index c6787b4c554..95049857d49 100644
--- a/source/blender/editors/interface/interface_intern.h
+++ b/source/blender/editors/interface/interface_intern.h
@@ -176,7 +176,7 @@ struct uiBut {
struct bContextStore *context;
- /* not ysed yet, was used in 2.4x for ui_draw_pulldown_round & friends */
+ /* not used yet, was used in 2.4x for ui_draw_pulldown_round & friends */
#if 0
void (*embossfunc)(int, int, float, float, float, float, float, int);
void (*sliderfunc)(int, float, float, float, float, float, float, int);
diff --git a/source/blender/editors/interface/interface_regions.c b/source/blender/editors/interface/interface_regions.c
index 70f2bf7b028..ce4043eea6a 100644
--- a/source/blender/editors/interface/interface_regions.c
+++ b/source/blender/editors/interface/interface_regions.c
@@ -573,6 +573,9 @@ ARegion *ui_tooltip_create(bContext *C, ARegion *butregion, uiBut *but)
char *str;
opptr = uiButGetOperatorPtrRNA(but); /* allocated when needed, the button owns it */
+ /* so the context is passed to itemf functions (some py itemf functions use it) */
+ WM_operator_properties_sanitize(opptr, FALSE);
+
str = WM_operator_pystring(C, but->optype, opptr, 0);
/* operator info */