When repainting a static control, with SS_BITMAP style, do not erase

the background. Keep sending the WM_CTLCOLORSTATIC notification as
Windows does.
This commit is contained in:
Rein Klazes 2004-05-25 04:03:21 +00:00 committed by Alexandre Julliard
parent 1a9ab88fe3
commit b64c89c59a
1 changed files with 2 additions and 5 deletions

View File

@ -555,15 +555,12 @@ static void STATIC_PaintIconfn( HWND hwnd, HDC hdc, DWORD style )
static void STATIC_PaintBitmapfn(HWND hwnd, HDC hdc, DWORD style )
{
RECT rc;
HBRUSH hbrush;
HDC hMemDC;
HBITMAP hBitmap, oldbitmap;
GetClientRect( hwnd, &rc );
hbrush = (HBRUSH)SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC,
/* message is still sent, even if the returned brush is not used */
SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC,
(WPARAM)hdc, (LPARAM)hwnd );
FillRect( hdc, &rc, hbrush );
if ((hBitmap = (HBITMAP)GetWindowLongA( hwnd, HICON_GWL_OFFSET )))
{