also add an InvalidateRect call before the BeginPaint in WM_PAINT

handler.this ensures the whole window is repainted, and hopefully fixes
some bug reports.



git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1384 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
dcnieho 2012-08-06 15:05:10 +00:00
parent 80ed4c02f9
commit d598173a25

View File

@ -559,7 +559,7 @@ LRESULT CALLBACK fgPlatformWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam,
case WM_PAINT: case WM_PAINT:
/* Turn on the visibility in case it was turned off somehow */ /* Turn on the visibility in case it was turned off somehow */
window->State.Visible = GL_TRUE; window->State.Visible = GL_TRUE;
InvalidateRect( hWnd, NULL, GL_FALSE ); /* Make sure whole window is repainted. Bt of a hack, but a safe on from what google turns up... */ InvalidateRect( hWnd, NULL, GL_FALSE ); /* Make sure whole window is repainted. Bit of a hack, but a safe on from what google turns up... */
BeginPaint( hWnd, &ps ); BeginPaint( hWnd, &ps );
fghRedrawWindow( window ); fghRedrawWindow( window );
EndPaint( hWnd, &ps ); EndPaint( hWnd, &ps );