mirror of
https://github.com/reactos/reactos.git
synced 2024-07-12 07:35:10 +00:00
Don't use DeleteDC on DC handles returned by GetDC.
svn path=/trunk/; revision=16747
This commit is contained in:
parent
1d059a1ddf
commit
fc8add5154
|
@ -290,8 +290,8 @@ HEADER_DrawItem (HWND hwnd, HDC hdc, INT iItem, BOOL bHotTrack)
|
|||
if (iw || bw) {
|
||||
HDC hClipDC = GetDC(hwnd);
|
||||
HRGN hClipRgn = CreateRectRgn(r.left, r.top, r.right, r.bottom);
|
||||
SelectClipRgn(hClipDC, hClipRgn);
|
||||
|
||||
SelectClipRgn(hClipDC, hClipRgn);
|
||||
if (bw) {
|
||||
HDC hdcBitmap = CreateCompatibleDC (hClipDC);
|
||||
SelectObject (hdcBitmap, phdi->hbm);
|
||||
|
@ -307,7 +307,7 @@ HEADER_DrawItem (HWND hwnd, HDC hdc, INT iItem, BOOL bHotTrack)
|
|||
}
|
||||
|
||||
DeleteObject(hClipRgn);
|
||||
DeleteDC(hClipDC);
|
||||
ReleaseDC(hwnd, hClipDC);
|
||||
}
|
||||
|
||||
if (((phdi->fmt & HDF_STRING)
|
||||
|
|
Loading…
Reference in a new issue