http://bugs.winehq.org/show_bug.cgi?id=20598
--- Comment #36 from BD bad_dude32065@yahoo.com 2010-01-11 20:28:26 --- (In reply to comment #35)
(In reply to comment #34)
(In reply to comment #33)
(In reply to comment #32)
i dont see any corruption
Black panel headers and black panel tab area.
ok, i see that. sorry for wasting you all's time. good luck on getting it fixed because its out of my league. ( i was having fun and learned a lot tho :) thanks for the patience.
i fixed it :)
INT WINAPI SetDIBits( HDC hdc, HBITMAP hbitmap, UINT startscan, UINT lines, LPCVOID bits, const BITMAPINFO *info, UINT coloruse ) { DC *dc; BITMAPOBJ *bitmap; INT result = 0; BOOL bDesktopDC = FALSE;
if (hdc == 0) { hdc = CreateCompatibleDC(0); bDesktopDC = TRUE; } if (!(dc = get_dc_ptr( hdc ))) return 0; update_dc( dc ); if (!(bitmap = GDI_GetObjPtr( hbitmap, OBJ_BITMAP ))) { release_dc_ptr( dc ); return 0; } if (!bitmap->funcs && !BITMAP_SetOwnerDC( hbitmap, dc )) goto done; result = lines; if (bitmap->funcs) { if (bitmap->funcs != dc->funcs) ERR( "not supported: DDB bitmap %p not belonging to device %p\n",
hbitmap, hdc ); else if (dc->funcs->pSetDIBits) result = dc->funcs->pSetDIBits( dc->physDev, hbitmap, startscan, lines, bits, info, coloruse ); }
done: GDI_ReleaseObj( hbitmap ); release_dc_ptr( dc ); return result; }
i added 2 release lines so complete code should be this:
INT WINAPI SetDIBits( HDC hdc, HBITMAP hbitmap, UINT startscan, UINT lines, LPCVOID bits, const BITMAPINFO *info, UINT coloruse ) { DC *dc; BITMAPOBJ *bitmap; INT result = 0; BOOL bDesktopDC = FALSE;
if (hdc == 0) { hdc = CreateCompatibleDC(0); bDesktopDC = TRUE; }
if (!(dc = get_dc_ptr( hdc ))) return 0;
update_dc( dc );
if (!(bitmap = GDI_GetObjPtr( hbitmap, OBJ_BITMAP ))) { release_dc_ptr( dc ); if (hdc == 0) DeleteDC(hdc); return 0; }
if (!bitmap->funcs && !BITMAP_SetOwnerDC( hbitmap, dc )) goto done;
result = lines; if (bitmap->funcs) { if (bitmap->funcs != dc->funcs) ERR( "not supported: DDB bitmap %p not belonging to device %p\n", hbitmap, hdc ); else if (dc->funcs->pSetDIBits) result = dc->funcs->pSetDIBits( dc->physDev, hbitmap, startscan, lines, bits, info, coloruse ); }
done: GDI_ReleaseObj( hbitmap ); release_dc_ptr( dc ); if (hdc == 0) DeleteDC(hdc); return result; }
please test and see if it all works ty