Module: wine Branch: master Commit: 5d6e052926c12518b587851540591a5ae5435efe URL: http://source.winehq.org/git/wine.git/?a=commit;h=5d6e052926c12518b587851540...
Author: Alexandre Julliard julliard@winehq.org Date: Wed Apr 21 14:56:37 2010 +0200
comctl32: Fix handling of bitmap header size for V4/V5 bitmaps.
---
dlls/comctl32/commctrl.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/dlls/comctl32/commctrl.c b/dlls/comctl32/commctrl.c index 1283bad..eb0f6b5 100644 --- a/dlls/comctl32/commctrl.c +++ b/dlls/comctl32/commctrl.c @@ -922,8 +922,7 @@ CreateMappedBitmap (HINSTANCE hInstance, INT_PTR idBitmap, UINT wFlags, if (hbm) { HDC hdcDst = CreateCompatibleDC (hdcScreen); HBITMAP hbmOld = SelectObject (hdcDst, hbm); - const BYTE *lpBits = (const BYTE *)(lpBitmap + 1); - lpBits += nColorTableSize * sizeof(RGBQUAD); + const BYTE *lpBits = (const BYTE *)lpBitmap + nSize; StretchDIBits (hdcDst, 0, 0, nWidth, nHeight, 0, 0, nWidth, nHeight, lpBits, (LPBITMAPINFO)lpBitmapInfo, DIB_RGB_COLORS, SRCCOPY);