Fix a regression in ImageList_Create when creating a dibsection.

This commit is contained in:
Maxime Bellengé 2004-02-24 00:58:59 +00:00 committed by Alexandre Julliard
parent 8fec392eaa
commit 820aa3762f
1 changed files with 3 additions and 2 deletions

View File

@ -599,9 +599,10 @@ ImageList_Create (INT cx, INT cy, UINT flags,
else
himl->uBitsPixel = (UINT)GetDeviceCaps (himl->hdcImage, BITSPIXEL);
if (himl->cMaxImage > 0)
if (himl->cMaxImage > 0) {
himl->hbmImage = ImageList_CreateImage(himl->hdcImage, himl, cx * himl->cMaxImage, cy);
else
SelectObject(himl->hdcImage, himl->hbmImage);
} else
himl->hbmImage = 0;
if ((himl->cMaxImage > 0) && (himl->flags & ILC_MASK)) {