diff --git a/dlls/comctl32/imagelist.c b/dlls/comctl32/imagelist.c index 0a923615d5b..2ee0eb4c8be 100644 --- a/dlls/comctl32/imagelist.c +++ b/dlls/comctl32/imagelist.c @@ -2272,6 +2272,16 @@ ImageList_Replace (HIMAGELIST himl, INT i, HBITMAP hbmImage, StretchBlt (hdcImageList, i * himl->cx, 0, himl->cx, himl->cy, hdcImage, 0, 0, bmp.bmWidth, bmp.bmHeight, SRCCOPY); + + + /* Remove the background from the image + */ + SelectObject (hdcImageList, himl->hbmImage); + StretchBlt (hdcImageList, + i*himl->cx, 0, himl->cx, himl->cy, + hdcImage, + 0, 0, bmp.bmWidth, bmp.bmHeight, + 0x220326); /* NOTSRCAND */ } DeleteDC (hdcImage);