comctl32: Limit the size of the header bitmap to 49x49.
This commit is contained in:
parent
d1be762464
commit
608ddd4742
|
@ -3269,15 +3269,16 @@ static LRESULT PROPSHEET_Paint(HWND hwnd, HDC hdcParam)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
int margin;
|
||||||
hbr = GetSysColorBrush(COLOR_WINDOW);
|
hbr = GetSysColorBrush(COLOR_WINDOW);
|
||||||
FillRect(hdc, &rzone, hbr);
|
FillRect(hdc, &rzone, hbr);
|
||||||
|
|
||||||
/* Draw the header bitmap. It's always centered like a
|
/* Draw the header bitmap. It's always centered like a
|
||||||
* common 49 x 49 bitmap. */
|
* common 49 x 49 bitmap. */
|
||||||
BitBlt(hdc, rzone.right - 49 - ((rzone.bottom - 49) / 2),
|
margin = (rzone.bottom - 49) / 2;
|
||||||
(rzone.bottom - 49) / 2,
|
BitBlt(hdc, rzone.right - 49 - margin, margin,
|
||||||
bm.bmWidth, bm.bmHeight,
|
min(bm.bmWidth, 49), min(bm.bmHeight, 49),
|
||||||
hdcSrc, 0, 0, SRCCOPY);
|
hdcSrc, 0, 0, SRCCOPY);
|
||||||
|
|
||||||
/* NOTE: Native COMCTL32 draws a white stripe over the bitmap
|
/* NOTE: Native COMCTL32 draws a white stripe over the bitmap
|
||||||
* if its height is smaller than 49 pixels. Because the reason
|
* if its height is smaller than 49 pixels. Because the reason
|
||||||
|
|
Loading…
Reference in New Issue