aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-10-23 01:09:52 +0200
committerSven Gothel <[email protected]>2012-10-23 01:09:52 +0200
commit953acae56d7cf60db712d8486a69552aac9ca6a1 (patch)
tree89c5c6f2f4b39d01f24c2e0decab01930c6111e6
parent27d3b3e990ae872a5935312ecaf42a12076fd3dc (diff)
Cleanup: Revert minor (semantic) differences introduced in f5612e7dfc635359f15b402c2ee9022a5e703a9d, in search of regression introduced w/ same commit
-rw-r--r--Jake2.sh2
-rw-r--r--src/jake2/Jake2.java19
-rwxr-xr-xsrc/jake2/Jake2Applet.java6
-rw-r--r--src/jake2/qcommon/Q2DataTool.java3
-rw-r--r--src/jake2/qcommon/Qcommon.java2
-rw-r--r--src/jake2/render/fast/Mesh.java1
-rw-r--r--src/jake2/render/opengl/NEWTWin.java1
7 files changed, 18 insertions, 16 deletions
diff --git a/Jake2.sh b/Jake2.sh
index 03de30c..3373805 100644
--- a/Jake2.sh
+++ b/Jake2.sh
@@ -9,7 +9,7 @@ CP=lib/jogamp/gluegen-rt.jar:lib/jogamp/joal.jar:lib/jogamp/jogl-all.jar:dist/li
X_ARGS="-Xmx100M"
# should be redundant (AWT not used anyways), however, due to a bug in avian, it's required
-D0_ARGS="-Djava.awt.headless=true"
+#D0_ARGS="-Djava.awt.headless=true"
#D_ARGS="-Dnewt.debug.Window.MouseEvent"
#D_ARGS="-Dnewt.debug.Window.KeyEvent"
diff --git a/src/jake2/Jake2.java b/src/jake2/Jake2.java
index 2d1385a..33d2544 100644
--- a/src/jake2/Jake2.java
+++ b/src/jake2/Jake2.java
@@ -25,6 +25,8 @@
*/
package jake2;
+import java.util.Locale;
+
import jake2.qcommon.*;
import jake2.sys.Timer;
@@ -35,8 +37,15 @@ import jake2.sys.Timer;
*/
public final class Jake2 {
- // public static Q2DataDialog Q2Dialog;
+ // public static Q2DataDialog q2DataTool;
public static Q2DataTool q2DataTool;
+
+ /* pp */ static final void initQ2DataTool() {
+ q2DataTool = new Q2DataTool();
+ // q2DataTool = new Q2DataDialog();
+ Locale.setDefault(Locale.US);
+ // q2DataTool.setVisible(true);
+ }
/**
* main is used to start the game. Quake2 for Java supports the following
@@ -79,12 +88,8 @@ public final class Jake2 {
// open the q2dialog, if we are not in dedicated mode.
- if (Globals.dedicated.value != 1.0f)
- {
- q2DataTool = new Q2DataTool();
- // Q2Dialog = new Q2DataDialog();
- // Locale.setDefault(Locale.US);
- // Q2Dialog.setVisible(true);
+ if (Globals.dedicated.value != 1.0f) {
+ Jake2.initQ2DataTool();
}
// in C the first arg is the filename
diff --git a/src/jake2/Jake2Applet.java b/src/jake2/Jake2Applet.java
index 62df6d3..91ce077 100755
--- a/src/jake2/Jake2Applet.java
+++ b/src/jake2/Jake2Applet.java
@@ -31,6 +31,7 @@ import jake2.sys.Timer;
import java.awt.BorderLayout;
import java.awt.Color;
+
import javax.swing.JApplet;
// import netscape.javascript.*;
@@ -103,10 +104,7 @@ public class Jake2Applet extends JApplet {
// open the q2dialog, if we are not in dedicated mode.
if (Globals.dedicated.value != 1.0f) {
- // Jake2.Q2Dialog = new Q2DataDialog();
- // Locale.setDefault(Locale.US);
- // Jake2.Q2Dialog.setVisible(true);
- Jake2.q2DataTool = new Q2DataTool();
+ Jake2.initQ2DataTool();
}
Qcommon.Init(new String[] { "Jake2" });
diff --git a/src/jake2/qcommon/Q2DataTool.java b/src/jake2/qcommon/Q2DataTool.java
index b12acfc..d9defaf 100644
--- a/src/jake2/qcommon/Q2DataTool.java
+++ b/src/jake2/qcommon/Q2DataTool.java
@@ -33,8 +33,7 @@ public class Q2DataTool {
}
}
- void destroy() {
-
+ void dispose() {
}
void setStatus(String text) {
diff --git a/src/jake2/qcommon/Qcommon.java b/src/jake2/qcommon/Qcommon.java
index 79f6f29..f6a757c 100644
--- a/src/jake2/qcommon/Qcommon.java
+++ b/src/jake2/qcommon/Qcommon.java
@@ -156,7 +156,7 @@ public final class Qcommon extends Globals {
CL.WriteConfiguration();
if (Globals.dedicated.value != 1.0f) {
- Jake2.q2DataTool.destroy();
+ Jake2.q2DataTool.dispose();
}
} catch (longjmpException e) {
diff --git a/src/jake2/render/fast/Mesh.java b/src/jake2/render/fast/Mesh.java
index 547be66..8b61bbb 100644
--- a/src/jake2/render/fast/Mesh.java
+++ b/src/jake2/render/fast/Mesh.java
@@ -35,7 +35,6 @@ import jake2.util.Lib;
import jake2.util.Math3D;
import java.nio.FloatBuffer;
-import java.nio.IntBuffer;
import java.nio.ShortBuffer;
/**
diff --git a/src/jake2/render/opengl/NEWTWin.java b/src/jake2/render/opengl/NEWTWin.java
index fe62060..2afecc4 100644
--- a/src/jake2/render/opengl/NEWTWin.java
+++ b/src/jake2/render/opengl/NEWTWin.java
@@ -171,6 +171,7 @@ public class NEWTWin {
}
window.requestFocus();
window.display(); // force GL resource validation
+ window.setAutoSwapBufferMode(false);
VID.Printf(Defines.PRINT_ALL, "...reques GLCaps "+window.getRequestedCapabilities()+'\n');
VID.Printf(Defines.PRINT_ALL, "...chosen GLCaps "+window.getChosenGLCapabilities()+'\n');