From 084f072aae73de39fecc35ac97d602b1db7d0d98 Mon Sep 17 00:00:00 2001 From: Julian Eisel Date: Wed, 22 Jan 2020 17:54:18 +0100 Subject: [PATCH] Fix T73191: Buttons in lower left of Preferences broken I'm still not entirely sure what was going on - I know that the execute region didn't get initialized correctly, but doing that at a later point didn't fix the issue. Apparently forcing the header region to re-initialize does fix it, even though I was sure this was redundant. Also fixes a memory leak in UI code after preferences were opened. --- source/blender/editors/screen/screen_ops.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/blender/editors/screen/screen_ops.c b/source/blender/editors/screen/screen_ops.c index 9ea8c8293d4..0e1ae03fd20 100644 --- a/source/blender/editors/screen/screen_ops.c +++ b/source/blender/editors/screen/screen_ops.c @@ -4843,7 +4843,10 @@ static int userpref_show_invoke(bContext *C, wmOperator *op, const wmEvent *even * So hiding in the temp window makes sense. */ ScrArea *area = CTX_wm_area(C); ARegion *region = BKE_area_find_region_type(area, RGN_TYPE_HEADER); + region->flag |= RGN_FLAG_HIDDEN; + ED_region_visibility_change_update(C, area, region); + return OPERATOR_FINISHED; } else {