The attached patch (by Toby Haynes I think) has not made it into CVS and I was wondering what needs to be done to make it accepatable. I know that it is a hack but it makes lotus work. Changelog : dlls/user/painting.c Hack to fix bug in lotus where keyboard input is not displayed Tony Lambregts tony_lambregts@telusplanet.net
Index: painting.c =================================================================== RCS file: /home/wine/wine/dlls/user/painting.c,v retrieving revision 1.2 diff -u -r1.2 painting.c --- painting.c 9 Mar 2002 23:44:30 -0000 1.2 +++ painting.c 7 May 2002 14:49:26 -0000 @@ -24,6 +24,7 @@ #include "wingdi.h" #include "wine/winuser16.h" #include "wine/server.h" +#include "gdi.h" #include "win.h" #include "dce.h" #include "wine/debug.h" @@ -148,7 +149,7 @@ /*********************************************************************** - * BeginPaint (USER32.@) + * BeginPaint (USER32.@) */ HDC WINAPI BeginPaint( HWND hwnd, PAINTSTRUCT *lps ) { @@ -235,10 +236,23 @@ /*********************************************************************** - * EndPaint (USER32.@) + * EndPaint (USER32.@) */ BOOL WINAPI EndPaint( HWND hwnd, const PAINTSTRUCT *lps ) { + WND *wnd; + if (hwnd && (wnd = WIN_FindWndPtr(hwnd))) + { /* FIXME : is this appropriate here !? */ + DWORD clsStyle = wnd->clsStyle; + WIN_ReleaseWndPtr(wnd); + if (clsStyle & CS_OWNDC) /* the dc has been reused */ + { /* restore visible region */ + HRGN hrgn=CreateRectRgn(0,0,0,0); + SetHookFlags16( lps->hdc, DCHF_INVALIDATEVISRGN ); + USER_Driver.pGetDC( hwnd, lps->hdc, hrgn, DCX_EXCLUDERGN ); + DeleteObject(hrgn); + } + } ReleaseDC( hwnd, lps->hdc ); ShowCaret( hwnd ); return TRUE;