X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=src%2Fmswin%2Ffg_main_mswin.c;h=f4a4919260faa9ad74f4db00f7399529e3059f57;hb=0f15fc81253f5e91c50c8e5922f981f8ee64556f;hp=a9f85528cba616ddc73b46a2ae671996075315e2;hpb=637e1260edb9068591665330c32407549ca36535;p=freeglut diff --git a/src/mswin/fg_main_mswin.c b/src/mswin/fg_main_mswin.c index a9f8552..f4a4919 100644 --- a/src/mswin/fg_main_mswin.c +++ b/src/mswin/fg_main_mswin.c @@ -75,6 +75,16 @@ void fgPlatformReshapeWindow ( SFG_Window *window, int width, int height ) * For windowed mode, get the current position of the * window and resize taking the size of the frame * decorations into account. + * + * Note on maximizing behavior of Windows: the resize borders are off + * the screen such that the client area extends all the way from the + * leftmost corner to the rightmost corner to maximize screen real + * estate. A caption is still shown however to allow interaction with + * the window controls. This is default behavior of Windows that + * FreeGLUT sticks with. To alter, one would have to check if + * WS_MAXIMIZE style is set when a resize event is triggered, and + * then manually correct the windowRect to put the borders back on + * screen. */ /* "GetWindowRect" returns the pixel coordinates of the outside of the window */ @@ -202,7 +212,7 @@ void fgPlatformMainLoopPreliminaryWork ( void ) /* - * Determine a GLUT modifer mask based on MS-WINDOWS system info. + * Determine a GLUT modifier mask based on MS-WINDOWS system info. */ static int fgPlatformGetModifiers (void) { @@ -498,7 +508,7 @@ LRESULT CALLBACK fgPlatformWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam, if (child_window) { - /* If child should have focus instead, set it here. */ + /* If we're dealing with a child window, make sure it has input focus instead, set it here. */ SetFocus(child_window->Window.Handle); SetActiveWindow( child_window->Window.Handle ); INVOKE_WCB( *child_window, Entry, ( GLUT_ENTERED ) ); @@ -556,7 +566,7 @@ LRESULT CALLBACK fgPlatformWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam, case WM_PAINT: /* Turn on the visibility in case it was turned off somehow */ window->State.Visible = GL_TRUE; - InvalidateRect( hWnd, NULL, GL_FALSE ); /* Make sure whole window is repainted. Bit 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 one from what google turns up... */ BeginPaint( hWnd, &ps ); fghRedrawWindow( window ); EndPaint( hWnd, &ps );