mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 08:25:03 +00:00
[WIN32SS][NTUSER] Fix MENU_DrawScrollArrows (#1753)
Fix drawing the menu scrolling arrows. CORE-13211
This commit is contained in:
parent
304e281099
commit
65e4efd475
1 changed files with 4 additions and 13 deletions
|
@ -2177,11 +2177,10 @@ static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect, PMENU lppop, PWND pwnd
|
|||
*/
|
||||
static void MENU_DrawScrollArrows(PMENU lppop, HDC hdc)
|
||||
{
|
||||
UINT arrow_bitmap_width, arrow_bitmap_height;
|
||||
RECT rect, dfcrc;
|
||||
UINT arrow_bitmap_height;
|
||||
RECT rect;
|
||||
UINT Flags = 0;
|
||||
|
||||
arrow_bitmap_width = gpsi->oembmi[OBI_DNARROW].cx;
|
||||
arrow_bitmap_height = gpsi->oembmi[OBI_DNARROW].cy;
|
||||
|
||||
rect.left = 0;
|
||||
|
@ -2189,22 +2188,14 @@ static void MENU_DrawScrollArrows(PMENU lppop, HDC hdc)
|
|||
rect.right = lppop->cxMenu;
|
||||
rect.bottom = arrow_bitmap_height;
|
||||
FillRect(hdc, &rect, IntGetSysColorBrush(COLOR_MENU));
|
||||
dfcrc.left = (lppop->cxMenu - arrow_bitmap_width) / 2;
|
||||
dfcrc.top = 0;
|
||||
dfcrc.right = arrow_bitmap_width;
|
||||
dfcrc.bottom = arrow_bitmap_height;
|
||||
DrawFrameControl(hdc, &dfcrc, DFC_MENU, (lppop->iTop ? 0 : DFCS_INACTIVE)|DFCS_MENUARROWUP);
|
||||
DrawFrameControl(hdc, &rect, DFC_MENU, (lppop->iTop ? 0 : DFCS_INACTIVE)|DFCS_MENUARROWUP);
|
||||
|
||||
rect.top = lppop->cyMenu - arrow_bitmap_height;
|
||||
rect.bottom = lppop->cyMenu;
|
||||
FillRect(hdc, &rect, IntGetSysColorBrush(COLOR_MENU));
|
||||
if (!(lppop->iTop < lppop->iMaxTop - (MENU_GetMaxPopupHeight(lppop) - 2 * arrow_bitmap_height)))
|
||||
Flags = DFCS_INACTIVE;
|
||||
dfcrc.left = (lppop->cxMenu - arrow_bitmap_width) / 2;
|
||||
dfcrc.top = lppop->cyMenu - arrow_bitmap_height;
|
||||
dfcrc.right = arrow_bitmap_width;
|
||||
dfcrc.bottom = lppop->cyMenu;
|
||||
DrawFrameControl(hdc, &dfcrc, DFC_MENU, Flags|DFCS_MENUARROWDOWN);
|
||||
DrawFrameControl(hdc, &rect, DFC_MENU, Flags|DFCS_MENUARROWDOWN);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
|
|
Loading…
Reference in a new issue