diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-11-26 09:43:58 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-11-26 09:44:33 +0300 |
commit | 945fddc4bec7d9471645c030b7f19c83afe72f0e (patch) | |
tree | d35f87e125815849158432e5a0aca244519687a6 /source/blender/editors/interface/interface_region_hud.c | |
parent | 16c46aabadf7d23750c6967785c434553bfc9570 (diff) |
UI: collapse redo panel by default
For some operators this fills a lot of vertical space,
users can expand it if they need.
Also remove workaround for T56752 (now fixed).
Diffstat (limited to 'source/blender/editors/interface/interface_region_hud.c')
-rw-r--r-- | source/blender/editors/interface/interface_region_hud.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/source/blender/editors/interface/interface_region_hud.c b/source/blender/editors/interface/interface_region_hud.c index aacb688b841..0d6877ae9be 100644 --- a/source/blender/editors/interface/interface_region_hud.c +++ b/source/blender/editors/interface/interface_region_hud.c @@ -134,6 +134,7 @@ static void hud_panels_register(ARegionType *art, int space_type, int region_typ pt->poll = hud_panel_operator_redo_poll; pt->space_type = space_type; pt->region_type = region_type; + pt->flag |= PNL_DEFAULT_CLOSED; BLI_addtail(&art->paneltypes, pt); } @@ -212,20 +213,7 @@ static void hud_region_draw(const bContext *C, ARegion *ar) GPU_clear(GPU_COLOR_BIT); if ((ar->flag & RGN_FLAG_HIDDEN) == 0) { - if (0) { - /* Has alpha flickering glitch, see T56752. */ - ui_draw_menu_back(NULL, NULL, &(rcti){.xmax = ar->winx, .ymax = ar->winy}); - } - else { - /* Use basic drawing instead. */ - bTheme *btheme = UI_GetTheme(); - float color[4]; - rgba_uchar_to_float(color, (const uchar *)btheme->tui.wcol_menu_back.inner); - const float radius = U.widget_unit * btheme->tui.wcol_menu_back.roundness; - UI_draw_roundbox_corner_set(UI_CNR_ALL); - UI_draw_roundbox_4fv(true, 0, 0, ar->winx, ar->winy, radius, color); - } - + ui_draw_menu_back(NULL, NULL, &(rcti){.xmax = ar->winx, .ymax = ar->winy}); ED_region_panels_draw(C, ar); } } |