mirror of
https://github.com/reactos/reactos.git
synced 2024-09-06 02:37:06 +00:00
Fixed one more bug, we did create wrong bpp if we got HDC = NULL for CreateDIBitmap, when I read wine code
it is always 1Bpp and 1Plans and we are doing same now if HDC is NULL, some wine test deepness on it. Hopply it will take care of some program problem. svn path=/trunk/; revision=23899
This commit is contained in:
parent
c6f105da0b
commit
7fe1969532
|
@ -796,6 +796,7 @@ HBITMAP STDCALL NtGdiCreateDIBitmap(HDC hDc, const BITMAPINFOHEADER *Header,
|
|||
|
||||
if (NULL == hDc)
|
||||
{
|
||||
BITMAPINFOHEADER *change_Header = (BITMAPINFOHEADER *)Header;
|
||||
hDc = IntGdiCreateDC(NULL, NULL, NULL, NULL,FALSE);
|
||||
if (hDc == NULL)
|
||||
{
|
||||
|
@ -810,6 +811,9 @@ HBITMAP STDCALL NtGdiCreateDIBitmap(HDC hDc, const BITMAPINFOHEADER *Header,
|
|||
return NULL;
|
||||
}
|
||||
|
||||
change_Header->biBitCount = 1;
|
||||
change_Header->biPlanes = 1;
|
||||
|
||||
Bmp = IntCreateDIBitmap(Dc, Header, Init, Bits, Data, ColorUse);
|
||||
DC_UnlockDc(Dc);
|
||||
NtGdiDeleteObjectApp(hDc);
|
||||
|
|
Loading…
Reference in a new issue