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/windowmanager/intern/wm_operators.c')
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index 6d008d5cbb3..8a9fb1fa5b5 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -774,8 +774,11 @@ static uiBlock *wm_block_create_redo(bContext *C, ARegion *ar, void *arg_op)
layout= uiBlockLayout(block, UI_LAYOUT_VERTICAL, UI_LAYOUT_PANEL, 0, 0, width, 20, style);
uiItemL(layout, op->type->name, 0);
- if(op->type->ui)
- op->type->ui((bContext*)C, op, layout);
+ if(op->type->ui) {
+ op->layout= layout;
+ op->type->ui((bContext*)C, op);
+ op->layout= NULL;
+ }
else
uiDefAutoButsRNA(C, layout, &ptr, columns);
@@ -808,8 +811,11 @@ static uiBlock *wm_operator_create_ui(bContext *C, ARegion *ar, void *userData)
RNA_pointer_create(&wm->id, op->type->srna, op->properties, &ptr);
layout= uiBlockLayout(block, UI_LAYOUT_VERTICAL, UI_LAYOUT_PANEL, 0, 0, data->width, data->height, style);
- if(op->type->ui)
- op->type->ui((bContext*)C, op, layout);
+ if(op->type->ui) {
+ op->layout= layout;
+ op->type->ui((bContext*)C, op);
+ op->layout= NULL;
+ }
uiPopupBoundsBlock(block, 4.0f, 0, 0);
uiEndBlock(C, block);
@@ -862,8 +868,11 @@ static uiBlock *wm_block_create_menu(bContext *C, ARegion *ar, void *arg_op)
layout= uiBlockLayout(block, UI_LAYOUT_VERTICAL, UI_LAYOUT_PANEL, 0, 0, 300, 20, style);
uiItemL(layout, op->type->name, 0);
- if(op->type->ui)
- op->type->ui(C, op, layout);
+ if(op->type->ui) {
+ op->layout= layout;
+ op->type->ui(C, op);
+ op->layout= NULL;
+ }
else
uiDefAutoButsRNA(C, layout, op->ptr, 2);