From b3ba41ecd1e1ed1cbb28b9fe90efb3c4f4e596c8 Mon Sep 17 00:00:00 2001 From: Julian Eisel Date: Tue, 4 May 2021 18:17:16 +0200 Subject: Fix missing background of buttons after reports Reports would change the active emboss of the Block, to make some of its buttons appear without background. But it didn't reset it so that buttons added afterwards wouldn't use the correct embossing. --- source/blender/editors/interface/interface_templates.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source') diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c index caeb52ab7e9..0484565ee2e 100644 --- a/source/blender/editors/interface/interface_templates.c +++ b/source/blender/editors/interface/interface_templates.c @@ -6830,6 +6830,7 @@ void uiTemplateReportsBanner(uiLayout *layout, bContext *C) uiLayout *ui_abs = uiLayoutAbsolute(layout, false); uiBlock *block = uiLayoutGetBlock(ui_abs); + eUIEmbossType previous_emboss = UI_block_emboss_get(block); UI_fontstyle_set(&style->widgetlabel); int width = BLF_width(style->widgetlabel.uifont_id, report->message, report->len); @@ -6904,6 +6905,8 @@ void uiTemplateReportsBanner(uiLayout *layout, bContext *C) width + UI_UNIT_X, UI_UNIT_Y, "Show in Info Log"); + + UI_block_emboss_set(block, previous_emboss); } void uiTemplateInputStatus(uiLayout *layout, struct bContext *C) -- cgit v1.2.3