[ros-diffs] [tkreuzer] 40276: Patch by Evgeniy Boltik: Always calculate a palette for the DIB in NtGdiGetDIBitsInternal, when dealing with 15 or 16 bit depth. Fixes broken taskbar icons on 16bpp.

tkreuzer at svn.reactos.org tkreuzer at svn.reactos.org
Sun Mar 29 01:25:48 CET 2009


Author: tkreuzer
Date: Sun Mar 29 04:25:47 2009
New Revision: 40276

URL: http://svn.reactos.org/svn/reactos?rev=40276&view=rev
Log:
Patch by Evgeniy Boltik: 
Always calculate a palette for the DIB in NtGdiGetDIBitsInternal, when dealing with 15 or 16 bit depth. Fixes broken taskbar icons on 16bpp.

Modified:
    trunk/reactos/subsystems/win32/win32k/objects/dibobj.c

Modified: trunk/reactos/subsystems/win32/win32k/objects/dibobj.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/objects/dibobj.c?rev=40276&r1=40275&r2=40276&view=diff
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/objects/dibobj.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/objects/dibobj.c [iso-8859-1] Sun Mar 29 04:25:47 2009
@@ -659,8 +659,10 @@
     ColorPtr = ((PBYTE)Info + Info->bmiHeader.biSize);
     rgbQuads = (RGBQUAD *)ColorPtr;
 
-    /* Copy palette information */
-    if (Info->bmiHeader.biBitCount == BitsPerFormat(psurf->SurfObj.iBitmapFormat))
+    /* Copy palette information
+     * Always create a palette for 15 & 16 bit. */
+    if (Info->bmiHeader.biBitCount == BitsPerFormat(psurf->SurfObj.iBitmapFormat) &&
+        Info->bmiHeader.biBitCount != 15 && Info->bmiHeader.biBitCount != 16)
     {
       hDestPalette = hSourcePalette;
       bPaletteMatch = TRUE;



More information about the Ros-diffs mailing list