"Alexandre Julliard" julliard@winehq.org wrote:
Actually that doesn't look right either, we shouldn't bypass the normal painting code IMO; but RedrawWindow(RDW_FRAME) would probably work better than SetWindowPos.
Here is an updated patch which works for me and also removes WM_SYSCOMMAND/SC_CLOSE filtering based on the CS_NOCLOSE test in DefWindowProc. My test under win2k shows that Windows sends WM_SYSCOMMAND/SC_CLOSE and then WM_CLOSE regardless whether CS_NOCLOSE is set or not.
Alexandre, I understand that you want to separate the drawing code from such cases and prevent a possible breakage of win31/etc. drawing code. But that's how it's done in Windows. It's up to you, if you wish, to replace the NC_DrawCloseButton95 call by RedrawWindow(RDW_FRAME) if you still think that it's cleaner to do.