Tidy nested if/else to suppress gcc -Wall -pedantic noise

gcc suggests explicit braces to avoid ambiguous `else'


git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@421 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
nigels 2003-12-30 01:52:07 +00:00
parent 5a8204816b
commit 5cc127d807

View File

@ -1377,11 +1377,14 @@ LRESULT CALLBACK fgWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam,
break; break;
} }
if( GetSystemMetrics( SM_SWAPBUTTON ) ) if ( GetSystemMetrics( SM_SWAPBUTTON ) )
if( button == GLUT_LEFT_BUTTON ) {
if ( button == GLUT_LEFT_BUTTON )
button = GLUT_RIGHT_BUTTON; button = GLUT_RIGHT_BUTTON;
else if( button == GLUT_RIGHT_BUTTON ) else
if ( button == GLUT_RIGHT_BUTTON )
button = GLUT_LEFT_BUTTON; button = GLUT_LEFT_BUTTON;
}
if( button == -1 ) if( button == -1 )
return DefWindowProc( hWnd, uMsg, lParam, wParam ); return DefWindowProc( hWnd, uMsg, lParam, wParam );