Author: hbelusca Date: Thu Mar 9 20:30:16 2017 New Revision: 74136
URL: http://svn.reactos.org/svn/reactos?rev=74136&view=rev Log: [COMCTL32]: comctl32/propsheet: Diverse UI fixes: - Draw static text elements with a transparent background, so that they acquire the correct background color of the wizard window. - Modify the check for the header bitmap, as the header's hbmHeader is initialized also if the flag PSH_HEADER but not PSH_USEHBMHEADER is set (see function PROPSHEET_LoadWizardBitmaps). - Add a check for header's hbmWatermark so that the watermark is drawn only when a valid bitmap handle is present. - Fix a copy-pasta error when drawing the header's subtitle.
CORE-12912 #comment Patch for the wizard visual problem sent upstream. CORE-12823
Modified: trunk/reactos/dll/win32/comctl32/propsheet.c
Modified: trunk/reactos/dll/win32/comctl32/propsheet.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/propshee... ============================================================================== --- trunk/reactos/dll/win32/comctl32/propsheet.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/propsheet.c [iso-8859-1] Thu Mar 9 20:30:16 2017 @@ -1176,8 +1176,13 @@ return TRUE;
case WM_CTLCOLORSTATIC: +#ifdef __REACTOS__ + SetBkMode((HDC)wParam, TRANSPARENT); + return (INT_PTR)GetStockObject(HOLLOW_BRUSH); +#else SetBkColor((HDC)wParam, GetSysColor(COLOR_WINDOW)); return (INT_PTR)GetSysColorBrush(COLOR_WINDOW); +#endif }
return DefSubclassProc(hwnd, uMsg, wParam, lParam); @@ -3281,7 +3286,11 @@
hOldFont = SelectObject(hdc, psInfo->hFontBold);
+#ifdef __REACTOS__ + if (psInfo->ppshheader.u5.hbmHeader) +#else if (psInfo->ppshheader.dwFlags & PSH_USEHBMHEADER) +#endif { hbmp = SelectObject(hdcSrc, psInfo->ppshheader.u5.hbmHeader);
@@ -3356,7 +3365,11 @@ if (ppshpage->dwFlags & PSP_USEHEADERSUBTITLE) { SelectObject(hdc, psInfo->hFont); SetRect(&r, 40, 25, rzone.right - 69, rzone.bottom); +#ifdef __REACTOS__ + if (!IS_INTRESOURCE(ppshpage->pszHeaderSubTitle)) +#else if (!IS_INTRESOURCE(ppshpage->pszHeaderTitle)) +#endif DrawTextW(hdc, ppshpage->pszHeaderSubTitle, -1, &r, DT_LEFT | DT_WORDBREAK); else { @@ -3378,7 +3391,12 @@
if ( (ppshpage && (ppshpage->dwFlags & PSP_HIDEHEADER)) && (psInfo->ppshheader.dwFlags & (PSH_WIZARD97_OLD | PSH_WIZARD97_NEW)) && +#ifdef __REACTOS__ + (psInfo->ppshheader.dwFlags & PSH_WATERMARK) && + (psInfo->ppshheader.u4.hbmWatermark) ) +#else (psInfo->ppshheader.dwFlags & PSH_WATERMARK) ) +#endif { HWND hwndLine = GetDlgItem(hwnd, IDC_SUNKEN_LINE);