mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 12:06:52 +00:00
[UXTHEME] -Fix for the 3rd or 4th time the bug where the caption window overflows over the caption buttons which was last broken by me in 74960. CORE-13435
svn path=/trunk/; revision=75439
This commit is contained in:
parent
8215152588
commit
fd3b42b706
1 changed files with 12 additions and 8 deletions
|
@ -305,6 +305,7 @@ void ThemeCalculateCaptionButtonsPos(HWND hWnd, HTHEME htheme)
|
|||
|
||||
static void
|
||||
ThemeDrawCaptionButton(PDRAW_CONTEXT pcontext,
|
||||
RECT* prcCurrent,
|
||||
CAPTIONBUTTON buttonId,
|
||||
INT iStateId)
|
||||
{
|
||||
|
@ -348,6 +349,9 @@ ThemeDrawCaptionButton(PDRAW_CONTEXT pcontext,
|
|||
return;
|
||||
}
|
||||
|
||||
if (prcCurrent)
|
||||
prcCurrent->right = pwndData->rcCaptionButtons[buttonId].left;
|
||||
|
||||
DrawThemeBackground(pcontext->theme, pcontext->hDC, iPartId, iStateId, &pwndData->rcCaptionButtons[buttonId], NULL);
|
||||
}
|
||||
|
||||
|
@ -369,13 +373,13 @@ static void
|
|||
ThemeDrawCaptionButtons(PDRAW_CONTEXT pcontext, DWORD htHot, DWORD htDown)
|
||||
{
|
||||
/* Draw the buttons */
|
||||
ThemeDrawCaptionButton(pcontext, CLOSEBUTTON,
|
||||
ThemeDrawCaptionButton(pcontext, NULL, CLOSEBUTTON,
|
||||
ThemeGetButtonState(HTCLOSE, htHot, htDown, pcontext->Active));
|
||||
ThemeDrawCaptionButton(pcontext, MAXBUTTON,
|
||||
ThemeDrawCaptionButton(pcontext, NULL, MAXBUTTON,
|
||||
ThemeGetButtonState(HTMAXBUTTON, htHot, htDown, pcontext->Active));
|
||||
ThemeDrawCaptionButton(pcontext, MINBUTTON,
|
||||
ThemeDrawCaptionButton(pcontext, NULL, MINBUTTON,
|
||||
ThemeGetButtonState(HTMINBUTTON, htHot, htDown, pcontext->Active));
|
||||
ThemeDrawCaptionButton(pcontext, HELPBUTTON,
|
||||
ThemeDrawCaptionButton(pcontext, NULL, HELPBUTTON,
|
||||
ThemeGetButtonState(HTHELP, htHot, htDown, pcontext->Active));
|
||||
}
|
||||
|
||||
|
@ -421,10 +425,10 @@ ThemeDrawCaption(PDRAW_CONTEXT pcontext, RECT* prcCurrent)
|
|||
{
|
||||
iState = pcontext->Active ? BUTTON_NORMAL : BUTTON_INACTIVE;
|
||||
|
||||
ThemeDrawCaptionButton(pcontext, CLOSEBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, MAXBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, MINBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, HELPBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, &rcPart, CLOSEBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, &rcPart, MAXBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, &rcPart, MINBUTTON, iState);
|
||||
ThemeDrawCaptionButton(pcontext, &rcPart, HELPBUTTON, iState);
|
||||
}
|
||||
|
||||
rcPart.top += 3 ;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue