mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-08 16:04:39 +00:00
Added closeRequested support to linux
This commit is contained in:
parent
36d8f34e86
commit
c022100cab
4 changed files with 99 additions and 78 deletions
|
|
@ -42,11 +42,13 @@
|
|||
#include "extgl.h"
|
||||
#include "org_lwjgl_opengl_BaseGL.h"
|
||||
|
||||
GLXContext context = NULL; // OpenGL rendering context
|
||||
static GLXContext context = NULL; // OpenGL rendering context
|
||||
extern XVisualInfo * getVisualInfo(void);
|
||||
extern Window win;
|
||||
extern Display * disp;
|
||||
|
||||
extern void handleMessages();
|
||||
|
||||
void makeCurrent(void) {
|
||||
glXMakeCurrent(disp, win, context);
|
||||
}
|
||||
|
|
@ -113,6 +115,7 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_BaseGL_nDestroy
|
|||
*/
|
||||
JNIEXPORT void JNICALL Java_org_lwjgl_opengl_BaseGL_swapBuffers(JNIEnv * env, jobject obj)
|
||||
{
|
||||
handleMessages();
|
||||
glXSwapBuffers(disp, win);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue