*/
void SampleMenu( int menuID )
{
- /*
- * Just print something funny
- */
printf( "SampleMenu() callback executed, menuID is %i\n", menuID );
}
/*
+ * A sample menu status callback
+ */
+void SampleMenuStatus( int status, int x, int y )
+{
+ printf ( "SampleMenu() callback executed, MenuStatus is %i at (%i,%i)\n", status, x, y );
+}
+
+/*
* The sample's entry point
*/
int main( int argc, char** argv )
glutSpecialFunc( SampleSpecial );
glutIdleFunc( SampleIdle );
glutEntryFunc( SampleEntry );
+ glutMenuStatusFunc( SampleMenuStatus );
glutAttachMenu( GLUT_LEFT_BUTTON );
glutInitWindowPosition( 200, 200 );
glutKeyboardFunc( SampleKeyboard );
glutSpecialFunc( SampleSpecial );
glutIdleFunc( SampleIdle );
+ glutEntryFunc( SampleEntry );
+ glutMenuStatusFunc( SampleMenuStatus );
glutAttachMenu( GLUT_LEFT_BUTTON );
glutSetMenu(subMenuA);
glutAttachMenu( GLUT_RIGHT_BUTTON );
glutReshapeFunc( SampleReshape );
glutKeyboardFunc( SampleGameModeKeyboard );
glutIdleFunc( SampleIdle );
+ glutEntryFunc( SampleEntry );
+ glutMenuStatusFunc( SampleMenuStatus );
glutSetMenu(menuID);
glutAttachMenu( GLUT_LEFT_BUTTON );