Commit 4082e9a6 authored by Alex Villacís Lasso's avatar Alex Villacís Lasso Committed by Alexandre Julliard

Do not issue a GetUpdateRect() to query an update region for

WM_PAINT(wParam=HDC) case. Instead, use GetClientRect() for a bounding rect.
parent 52e8200c
......@@ -2849,18 +2849,8 @@ TREEVIEW_Paint(TREEVIEW_INFO *infoPtr, WPARAM wParam)
if (wParam)
{
hdc = (HDC)wParam;
if (!GetUpdateRect(infoPtr->hwnd, &rc, TRUE))
{
HBITMAP hbitmap;
BITMAP bitmap;
hbitmap = GetCurrentObject(hdc, OBJ_BITMAP);
if (!hbitmap) return 0;
GetObjectW(hbitmap, sizeof(BITMAP), &bitmap);
rc.left = 0; rc.top = 0;
rc.right = bitmap.bmWidth;
rc.bottom = bitmap.bmHeight;
TREEVIEW_EraseBackground(infoPtr, (HDC)wParam);
}
GetClientRect(infoPtr->hwnd, &rc);
TREEVIEW_EraseBackground(infoPtr, hdc);
}
else
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment