From: <eli...@us...> - 2007-01-04 13:44:25
|
Revision: 2715 http://svn.sourceforge.net/java-game-lib/?rev=2715&view=rev Author: elias_naur Date: 2007-01-04 05:44:23 -0800 (Thu, 04 Jan 2007) Log Message: ----------- Windows: Re-add UpdateWindow to make sure fullscreen windows are cleared faster Modified Paths: -------------- trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDisplay.java trunk/LWJGL/src/native/windows/org_lwjgl_opengl_Display.c Modified: trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDisplay.java =================================================================== --- trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDisplay.java 2007-01-03 09:16:13 UTC (rev 2714) +++ trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDisplay.java 2007-01-04 13:44:23 UTC (rev 2715) @@ -136,6 +136,7 @@ showWindow(getHwnd(), SW_SHOWDEFAULT); setForegroundWindow(getHwnd()); setFocus(getHwnd()); + updateWindow(getHwnd()); } private native void nCreateWindow(DisplayMode mode, boolean fullscreen, int x, int y) throws LWJGLException; @@ -181,6 +182,7 @@ private static native void showWindow(long hwnd, int mode); private static native void setForegroundWindow(long hwnd); private static native void setFocus(long hwnd); + private static native void updateWindow(long hwnd); private void restoreDisplayMode() { try { Modified: trunk/LWJGL/src/native/windows/org_lwjgl_opengl_Display.c =================================================================== --- trunk/LWJGL/src/native/windows/org_lwjgl_opengl_Display.c 2007-01-03 09:16:13 UTC (rev 2714) +++ trunk/LWJGL/src/native/windows/org_lwjgl_opengl_Display.c 2007-01-04 13:44:23 UTC (rev 2715) @@ -247,6 +247,11 @@ setGammaRamp(env, gamma_buffer); } +JNIEXPORT void JNICALL Java_org_lwjgl_opengl_WindowsDisplay_updateWindow(JNIEnv *env, jclass unused, jlong hwnd_ptr) { + HWND hwnd = (HWND)(INT_PTR)hwnd_ptr; + UpdateWindow(hwnd); +} + JNIEXPORT void JNICALL Java_org_lwjgl_opengl_WindowsDisplay_showWindow(JNIEnv *env, jclass unused, jlong hwnd_ptr, jint mode) { HWND hwnd = (HWND)(INT_PTR)hwnd_ptr; ShowWindow(hwnd, mode); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |