http://bugs.winehq.org/show_bug.cgi?id=18145
--- Comment #6 from Nikolay Sivov bunglehead@gmail.com 2009-12-29 07:05:51 --- (In reply to comment #3)
(In reply to comment #2)
Probably what happens is that FillRect() ignores an error of SelectObject() when an invalid brush handle is passed. That needs a test case.
#1. FillRect && GetSysColorBrush FillRect code: ... if ( hbrush <= (HBRUSH) (COLOR_MAX + 1)) hbrush = GetSysColorBrush( HandleToULong(hbrush) - 1 ); ...
GetSysColorBrush( (unsigned) -1 ) returns NULL under windows, but wine returns GetStockObject( LTGRAY_BRUSH ).
I sent a test patch for GetSysColorBrush().
http://www.winehq.org/pipermail/wine-patches/2009-December/083287.html
BTW, what Wine version did you try first?