diff --git a/src/kits/opengl/glut/Jamfile b/src/kits/opengl/glut/Jamfile index c98ceb2875..7eeb038d14 100644 --- a/src/kits/opengl/glut/Jamfile +++ b/src/kits/opengl/glut/Jamfile @@ -1,5 +1,12 @@ SubDir HAIKU_TOP src kits opengl glut ; +SetSubDirSupportedPlatformsBeOSCompatible ; + +if $(TARGET_PLATFORM) != haiku { + UseHeaders [ FDirName $(HAIKU_TOP) headers os opengl ] : true ; + # We need the public GL headers also when not compiling for Haiku. +} + MergeObject glut.o : # C++ sources glutBlocker.cpp diff --git a/src/kits/opengl/glut/glutCallback.cpp b/src/kits/opengl/glut/glutCallback.cpp index cf3daaaf36..be56d4637b 100644 --- a/src/kits/opengl/glut/glutCallback.cpp +++ b/src/kits/opengl/glut/glutCallback.cpp @@ -37,12 +37,24 @@ glutKeyboardFunc(GLUTkeyboardCB keyboardFunc) gState.currentWindow->keyboard = keyboardFunc; } +void APIENTRY +glutKeyboardUpFunc(GLUTkeyboardCB keyboardUpFunc) +{ + gState.currentWindow->keyboardUp = keyboardUpFunc; +} + void APIENTRY glutSpecialFunc(GLUTspecialCB specialFunc) { gState.currentWindow->special = specialFunc; } +void APIENTRY +glutSpecialUpFunc(GLUTspecialCB specialUpFunc) +{ + gState.currentWindow->specialUp = specialUpFunc; +} + void APIENTRY glutMouseFunc(GLUTmouseCB mouseFunc) { @@ -135,6 +147,11 @@ glutOverlayDisplayFunc(GLUTdisplayCB displayFunc) { } +void APIENTRY +glutJoystickFunc(GLUTjoystickCB joystickFunc, int pollInterval) +{ +} + void APIENTRY glutSpaceballMotionFunc(GLUTspaceMotionCB spaceMotionFunc) { diff --git a/src/kits/opengl/glut/glutWindow.h b/src/kits/opengl/glut/glutWindow.h index d3ac186269..5374e651fe 100644 --- a/src/kits/opengl/glut/glutWindow.h +++ b/src/kits/opengl/glut/glutWindow.h @@ -63,8 +63,10 @@ public: GLUTpassiveCB passive; /* passive motion (x,y) */ GLUTentryCB entry; /* window entry/exit (state) */ GLUTkeyboardCB keyboard; /* keyboard (ASCII,x,y) */ + GLUTkeyboardCB keyboardUp; /* keyboard up (ASCII,x,y) */ GLUTvisibilityCB visibility; /* visibility */ GLUTspecialCB special; /* special key */ + GLUTspecialCB specialUp; /* special key up */ GLUTwindowStatusCB windowStatus; /* window status */ bool anyevents; // were any events received?