diff --git a/src/java/org/lwjgl/opengl/Window.java b/src/java/org/lwjgl/opengl/Window.java index f50146d6..d03ff18c 100644 --- a/src/java/org/lwjgl/opengl/Window.java +++ b/src/java/org/lwjgl/opengl/Window.java @@ -329,9 +329,8 @@ public final class Window { } /** - * 'Tick' the window. This must be called at least once per video frame + * Updates the windows internal state. This must be called at least once per video frame * to handle window close requests, moves, paints, etc. */ - public static native void tick(); - + public static native void updateState(); } diff --git a/src/java/org/lwjgl/test/WindowCreationTest.java b/src/java/org/lwjgl/test/WindowCreationTest.java index b24dff0e..16035e8a 100644 --- a/src/java/org/lwjgl/test/WindowCreationTest.java +++ b/src/java/org/lwjgl/test/WindowCreationTest.java @@ -31,7 +31,7 @@ public class WindowCreationTest { System.out.println("Display created"); while(!Window.isCloseRequested()) { - Window.tick(); + Window.updateState(); try { Thread.sleep(100); } catch (Exception e) { diff --git a/src/java/org/lwjgl/test/input/ControllerCreationTest.java b/src/java/org/lwjgl/test/input/ControllerCreationTest.java index 15d0db6b..fb44bbed 100644 --- a/src/java/org/lwjgl/test/input/ControllerCreationTest.java +++ b/src/java/org/lwjgl/test/input/ControllerCreationTest.java @@ -160,7 +160,7 @@ public class ControllerCreationTest { while (Sys.getTime() < endtime) { - Window.tick(); + Window.updateState(); Controller.poll(); diff --git a/src/java/org/lwjgl/test/input/ControllerTest.java b/src/java/org/lwjgl/test/input/ControllerTest.java index 960a9a07..6ce1d408 100644 --- a/src/java/org/lwjgl/test/input/ControllerTest.java +++ b/src/java/org/lwjgl/test/input/ControllerTest.java @@ -113,7 +113,7 @@ public class ControllerTest { private void wiggleController() { while (!Window.isCloseRequested()) { - Window.tick(); + Window.updateState(); if(Window.isMinimized()) { try { diff --git a/src/java/org/lwjgl/test/input/HWCursorTest.java b/src/java/org/lwjgl/test/input/HWCursorTest.java index 0477f8c1..58a67f33 100644 --- a/src/java/org/lwjgl/test/input/HWCursorTest.java +++ b/src/java/org/lwjgl/test/input/HWCursorTest.java @@ -149,7 +149,7 @@ public class HWCursorTest { while (!Keyboard.isKeyDown(Keyboard.KEY_ESCAPE) && !Window.isCloseRequested()) { // allow subsystem to get a chance to run too - Window.tick(); + Window.updateState(); if (!Window.isMinimized()) { // check keyboard input diff --git a/src/java/org/lwjgl/test/input/KeyboardTest.java b/src/java/org/lwjgl/test/input/KeyboardTest.java index 5d60fd4e..a066afee 100644 --- a/src/java/org/lwjgl/test/input/KeyboardTest.java +++ b/src/java/org/lwjgl/test/input/KeyboardTest.java @@ -118,7 +118,7 @@ public class KeyboardTest { Keyboard.enableTranslation(); while (!Window.isCloseRequested()) { - Window.tick(); + Window.updateState(); if(Window.isMinimized()) { try { diff --git a/src/java/org/lwjgl/test/input/MouseCreationTest.java b/src/java/org/lwjgl/test/input/MouseCreationTest.java index f5d23b3e..7248a55d 100644 --- a/src/java/org/lwjgl/test/input/MouseCreationTest.java +++ b/src/java/org/lwjgl/test/input/MouseCreationTest.java @@ -162,7 +162,7 @@ public class MouseCreationTest { long endtime = Sys.getTime() + Sys.getTimerResolution() * 5; while (Sys.getTime() < endtime) { - Window.tick(); + Window.updateState(); Mouse.poll(); diff --git a/src/java/org/lwjgl/test/input/MouseTest.java b/src/java/org/lwjgl/test/input/MouseTest.java index e504b61d..230cf196 100644 --- a/src/java/org/lwjgl/test/input/MouseTest.java +++ b/src/java/org/lwjgl/test/input/MouseTest.java @@ -113,7 +113,7 @@ public class MouseTest { private void wiggleMouse() { while (!Window.isCloseRequested()) { - Window.tick(); + Window.updateState(); if(Window.isMinimized()) { try { diff --git a/src/java/org/lwjgl/test/openal/MovingSoundTest.java b/src/java/org/lwjgl/test/openal/MovingSoundTest.java index 0f8c7106..598d00d5 100644 --- a/src/java/org/lwjgl/test/openal/MovingSoundTest.java +++ b/src/java/org/lwjgl/test/openal/MovingSoundTest.java @@ -156,7 +156,7 @@ public class MovingSoundTest extends BasicTest { System.out.println("Move source with arrow keys\nMove listener with right shift and arrowkeys\nEnable EAX effect by pressing e (if available)\nExit with ESC"); while(!Keyboard.isKeyDown(Keyboard.KEY_ESCAPE)) { - Window.tick(); + Window.updateState(); Keyboard.poll(); if(Keyboard.isKeyDown(Keyboard.KEY_LEFT)) { diff --git a/src/java/org/lwjgl/test/opengl/FullScreenWindowedTest.java b/src/java/org/lwjgl/test/opengl/FullScreenWindowedTest.java index ee5275dd..0f72363c 100644 --- a/src/java/org/lwjgl/test/opengl/FullScreenWindowedTest.java +++ b/src/java/org/lwjgl/test/opengl/FullScreenWindowedTest.java @@ -113,7 +113,7 @@ public class FullScreenWindowedTest { while (!Keyboard.isKeyDown(Keyboard.KEY_ESCAPE) && !Window.isCloseRequested()) { // allow subsystem to get a chance to run too - Window.tick(); + Window.updateState(); if (!Window.isMinimized()) { // check keyboard input diff --git a/src/java/org/lwjgl/test/opengl/Game.java b/src/java/org/lwjgl/test/opengl/Game.java index 1d2365f5..328d2c31 100644 --- a/src/java/org/lwjgl/test/opengl/Game.java +++ b/src/java/org/lwjgl/test/opengl/Game.java @@ -98,7 +98,7 @@ public final class Game { try { init(); while (!finished) { - Window.tick(); + Window.updateState(); if (Window.isMinimized()) Thread.sleep(200); diff --git a/src/java/org/lwjgl/test/opengl/PbufferTest.java b/src/java/org/lwjgl/test/opengl/PbufferTest.java index f6230d5d..d5731bc9 100644 --- a/src/java/org/lwjgl/test/opengl/PbufferTest.java +++ b/src/java/org/lwjgl/test/opengl/PbufferTest.java @@ -122,7 +122,7 @@ public class PbufferTest { while (!Keyboard.isKeyDown(Keyboard.KEY_ESCAPE) && !Window.isCloseRequested()) { // allow subsystem to get a chance to run too - Window.tick(); + Window.updateState(); if (!Window.isMinimized()) { // check keyboard input diff --git a/src/java/org/lwjgl/test/opengl/VBOIndexTest.java b/src/java/org/lwjgl/test/opengl/VBOIndexTest.java index 5988def9..4a423111 100644 --- a/src/java/org/lwjgl/test/opengl/VBOIndexTest.java +++ b/src/java/org/lwjgl/test/opengl/VBOIndexTest.java @@ -100,7 +100,7 @@ public final class VBOIndexTest { try { init(); while (!finished) { - Window.tick(); + Window.updateState(); if (Window.isMinimized()) Thread.sleep(200); diff --git a/src/java/org/lwjgl/test/opengl/VBOTest.java b/src/java/org/lwjgl/test/opengl/VBOTest.java index d7eceaf6..ad001f78 100644 --- a/src/java/org/lwjgl/test/opengl/VBOTest.java +++ b/src/java/org/lwjgl/test/opengl/VBOTest.java @@ -96,7 +96,7 @@ public final class VBOTest { try { init(); while (!finished) { - Window.tick(); + Window.updateState(); if (Window.isMinimized()) Thread.sleep(200); diff --git a/src/native/common/org_lwjgl_opengl_Window.h b/src/native/common/org_lwjgl_opengl_Window.h index 2f93e5c2..ad2a1fd4 100644 --- a/src/native/common/org_lwjgl_opengl_Window.h +++ b/src/native/common/org_lwjgl_opengl_Window.h @@ -102,10 +102,10 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_nDestroy /* * Class: org_lwjgl_opengl_Window - * Method: tick + * Method: updateState * Signature: ()V */ -JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_tick +JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_updateState (JNIEnv *, jclass); #ifdef __cplusplus diff --git a/src/native/linux/org_lwjgl_opengl_Window.cpp b/src/native/linux/org_lwjgl_opengl_Window.cpp index d25aaba8..b3e48fb2 100644 --- a/src/native/linux/org_lwjgl_opengl_Window.cpp +++ b/src/native/linux/org_lwjgl_opengl_Window.cpp @@ -256,10 +256,10 @@ int getWindowHeight(void) { /* * Class: org_lwjgl_Window - * Method: tick + * Method: updateState * Signature: ()V */ -JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_tick +JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_updateState (JNIEnv *env, jclass clazz) { handleMessages(); diff --git a/src/native/win32/org_lwjgl_opengl_Window.cpp b/src/native/win32/org_lwjgl_opengl_Window.cpp index 098fd9d9..78e08e93 100755 --- a/src/native/win32/org_lwjgl_opengl_Window.cpp +++ b/src/native/win32/org_lwjgl_opengl_Window.cpp @@ -477,10 +477,10 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_nSetTitle /* * Class: org_lwjgl_Window - * Method: tick + * Method: updateState * Signature: ()V */ -JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_tick +JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Window_updateState (JNIEnv * env, jclass clazz) { handleMessages(env, clazz);