Hopefully removed all damage done by commits without merge

git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@561 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
spanne 2005-01-05 14:28:22 +00:00
parent ac2e30aecd
commit b1e9a6e16d
5 changed files with 14 additions and 13 deletions

View File

@ -174,6 +174,8 @@ static struct name_address_pair glut_functions[] =
{ "glutSolidRhombicDodecahedron", (void *) glutSolidRhombicDodecahedron }, { "glutSolidRhombicDodecahedron", (void *) glutSolidRhombicDodecahedron },
{ "glutWireSierpinskiSponge", (void *) glutWireSierpinskiSponge }, { "glutWireSierpinskiSponge", (void *) glutWireSierpinskiSponge },
{ "glutSolidSierpinskiSponge", (void *) glutSolidSierpinskiSponge }, { "glutSolidSierpinskiSponge", (void *) glutSolidSierpinskiSponge },
{ "glutWireCylinder", (void *) glutWireCylinder },
{ "glutSolidCylinder", (void *) glutSolidCylinder },
{ "glutGetProcAddress", (void *) glutGetProcAddress }, { "glutGetProcAddress", (void *) glutGetProcAddress },
{ "glutMouseWheelFunc", (void *) glutMouseWheelFunc }, { "glutMouseWheelFunc", (void *) glutMouseWheelFunc },
{ NULL, NULL } { NULL, NULL }

View File

@ -153,7 +153,7 @@ void FGAPIENTRY glutBitmapString( void* fontID, const unsigned char *string )
* point back to the start of the line and down one line. * point back to the start of the line and down one line.
*/ */
while( ( c = *string++) ) while( ( c = *string++) )
if( string[c] == '\n' ) if( c == '\n' )
{ {
glBitmap ( 0, 0, 0, 0, -x, (float) -font->Height, NULL ); glBitmap ( 0, 0, 0, 0, -x, (float) -font->Height, NULL );
x = 0.0f; x = 0.0f;

View File

@ -487,7 +487,7 @@ static void fghSleepForEvents( void )
wait.tv_usec = (msec % 1000) * 1000; wait.tv_usec = (msec % 1000) * 1000;
err = select( socket+1, &fdset, NULL, NULL, &wait ); err = select( socket+1, &fdset, NULL, NULL, &wait );
if( -1 == err ) if( ( -1 == err ) && ( errno != EINTR ) )
fgWarning ( "freeglut select() error: %d", errno ); fgWarning ( "freeglut select() error: %d", errno );
} }
#elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE #elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE

View File

@ -555,8 +555,7 @@ int FGAPIENTRY glutDeviceGet( GLenum eWhat )
return fgStructure.Window ? fgStructure.Window->State.IgnoreKeyRepeat : 0; return fgStructure.Window ? fgStructure.Window->State.IgnoreKeyRepeat : 0;
case GLUT_DEVICE_KEY_REPEAT: case GLUT_DEVICE_KEY_REPEAT:
/* XXX WARNING: THIS IS A BIG LIE! */ return fgState.KeyRepeat;
return GLUT_KEY_REPEAT_DEFAULT;
default: default:
fgWarning( "glutDeviceGet(): missing enum handle %d", eWhat ); fgWarning( "glutDeviceGet(): missing enum handle %d", eWhat );

View File

@ -316,7 +316,7 @@ void fgOpenWindow( SFG_Window* window, const char* title,
*/ */
winAttr.event_mask = winAttr.event_mask =
StructureNotifyMask | SubstructureNotifyMask | ExposureMask | StructureNotifyMask | SubstructureNotifyMask | ExposureMask |
ButtonPressMask | ButtonReleaseMask | KeyPressMask | KeyRelease | ButtonPressMask | ButtonReleaseMask | KeyPressMask | KeyReleaseMask |
VisibilityChangeMask | EnterWindowMask | LeaveWindowMask | VisibilityChangeMask | EnterWindowMask | LeaveWindowMask |
PointerMotionMask | ButtonMotionMask; PointerMotionMask | ButtonMotionMask;
winAttr.background_pixmap = None; winAttr.background_pixmap = None;
@ -401,12 +401,6 @@ void fgOpenWindow( SFG_Window* window, const char* title,
} }
#endif #endif
glXMakeCurrent(
fgDisplay.Display,
window->Window.Handle,
window->Window.Context
);
/* /*
* XXX Assume the new window is visible by default * XXX Assume the new window is visible by default
* XXX Is this a safe assumption? * XXX Is this a safe assumption?
@ -452,6 +446,12 @@ void fgOpenWindow( SFG_Window* window, const char* title,
XSetWMProtocols( fgDisplay.Display, window->Window.Handle, XSetWMProtocols( fgDisplay.Display, window->Window.Handle,
&fgDisplay.DeleteWindow, 1 ); &fgDisplay.DeleteWindow, 1 );
glXMakeCurrent(
fgDisplay.Display,
window->Window.Handle,
window->Window.Context
);
XMapWindow( fgDisplay.Display, window->Window.Handle ); XMapWindow( fgDisplay.Display, window->Window.Handle );
#elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE #elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE