-forgot to check lpDrawItem->CtlID

svn path=/trunk/; revision=22147
This commit is contained in:
Christoph von Wittich 2006-06-01 16:34:53 +00:00
parent bf90c28bb1
commit 130257e46c

View file

@ -809,18 +809,21 @@ TimeZonePageProc(HWND hwndDlg,
case WM_DRAWITEM:
{
LPDRAWITEMSTRUCT lpDrawItem;
PAINTSTRUCT ps;
HDC hdc, hdcMem;
lpDrawItem = (LPDRAWITEMSTRUCT) lParam;
hdc = BeginPaint(hwndDlg, &ps);
hdcMem = CreateCompatibleDC(hdc);
SelectObject(hdcMem, hBitmap);
StretchBlt(lpDrawItem->hDC, lpDrawItem->rcItem.left, lpDrawItem->rcItem.top,
lpDrawItem->rcItem.right - lpDrawItem->rcItem.left,
lpDrawItem->rcItem.bottom - lpDrawItem->rcItem.top,
hdcMem, 0, 0, cxSource, cySource, SRCCOPY);
DeleteDC(hdcMem);
EndPaint(hwndDlg, &ps);
if(lpDrawItem->CtlID == IDC_WORLD_BACKGROUND)
{
PAINTSTRUCT ps;
HDC hdc, hdcMem;
hdc = BeginPaint(hwndDlg, &ps);
hdcMem = CreateCompatibleDC(hdc);
SelectObject(hdcMem, hBitmap);
StretchBlt(lpDrawItem->hDC, lpDrawItem->rcItem.left, lpDrawItem->rcItem.top,
lpDrawItem->rcItem.right - lpDrawItem->rcItem.left,
lpDrawItem->rcItem.bottom - lpDrawItem->rcItem.top,
hdcMem, 0, 0, cxSource, cySource, SRCCOPY);
DeleteDC(hdcMem);
EndPaint(hwndDlg, &ps);
}
break;
}
case WM_COMMAND: