aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/javax
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-03-13 20:19:19 +0100
committerSven Gothel <[email protected]>2012-03-13 20:19:19 +0100
commit7d7e7c901d8fe54af1230cbf10e568f1a8433cbe (patch)
treefe878a3776be351faa3c3f7f10583af5f38c112d /src/jogl/classes/javax
parent558a674f5ed727be1536cffd882d43458ce47a37 (diff)
Adapt to gluegen Properties/Security commits f4ac27e177f6deb444280d3b375e7d343e38bd080 and eedb4b530fb83fc59a26962bcf7847a1404092a0
Diffstat (limited to 'src/jogl/classes/javax')
-rw-r--r--src/jogl/classes/javax/media/opengl/DefaultGLCapabilitiesChooser.java7
-rw-r--r--src/jogl/classes/javax/media/opengl/GLAutoDrawable.java3
-rw-r--r--src/jogl/classes/javax/media/opengl/GLContext.java15
-rw-r--r--src/jogl/classes/javax/media/opengl/GLDrawableFactory.java5
-rw-r--r--src/jogl/classes/javax/media/opengl/awt/GLJPanel.java10
5 files changed, 13 insertions, 27 deletions
diff --git a/src/jogl/classes/javax/media/opengl/DefaultGLCapabilitiesChooser.java b/src/jogl/classes/javax/media/opengl/DefaultGLCapabilitiesChooser.java
index 8aa6d5165..f678c709e 100644
--- a/src/jogl/classes/javax/media/opengl/DefaultGLCapabilitiesChooser.java
+++ b/src/jogl/classes/javax/media/opengl/DefaultGLCapabilitiesChooser.java
@@ -41,12 +41,11 @@
package javax.media.opengl;
import javax.media.nativewindow.NativeWindowException;
-import jogamp.opengl.Debug;
-
-import java.security.AccessController;
import java.util.List;
import javax.media.nativewindow.CapabilitiesImmutable;
+import jogamp.opengl.Debug;
+
/** <P> The default implementation of the {@link
GLCapabilitiesChooser} interface, which provides consistent visual
selection behavior across platforms. The precise algorithm is
@@ -86,7 +85,7 @@ import javax.media.nativewindow.CapabilitiesImmutable;
*/
public class DefaultGLCapabilitiesChooser implements GLCapabilitiesChooser {
- private static final boolean DEBUG = Debug.isPropertyDefined("jogl.debug.CapabilitiesChooser", true, AccessController.getContext());
+ private static final boolean DEBUG = Debug.isPropertyDefined("jogl.debug.CapabilitiesChooser", true);
final static int NO_SCORE = -9999999;
final static int DOUBLE_BUFFER_MISMATCH_PENALTY = 1000;
diff --git a/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java b/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
index 9484f0656..c427a9804 100644
--- a/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
+++ b/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
@@ -41,7 +41,6 @@
package javax.media.opengl;
import jogamp.opengl.Debug;
-import java.security.*;
/** A higher-level abstraction than {@link GLDrawable} which supplies
an event based mechanism ({@link GLEventListener}) for performing
@@ -113,7 +112,7 @@ public interface GLAutoDrawable extends GLDrawable {
/** Flag reflecting wheather the drawable reconfiguration will be issued in
* case a screen device change occured, e.g. in a multihead environment,
* where you drag the window to another monitor. */
- public static final boolean SCREEN_CHANGE_ACTION_ENABLED = Debug.getBooleanProperty("jogl.screenchange.action", true, AccessController.getContext());
+ public static final boolean SCREEN_CHANGE_ACTION_ENABLED = Debug.getBooleanProperty("jogl.screenchange.action", true);
/**
* Returns the context associated with this drawable. The returned
diff --git a/src/jogl/classes/javax/media/opengl/GLContext.java b/src/jogl/classes/javax/media/opengl/GLContext.java
index cc6b40f54..f928bc126 100644
--- a/src/jogl/classes/javax/media/opengl/GLContext.java
+++ b/src/jogl/classes/javax/media/opengl/GLContext.java
@@ -41,8 +41,6 @@
package javax.media.opengl;
import java.nio.IntBuffer;
-import java.security.AccessControlContext;
-import java.security.AccessController;
import java.util.HashMap;
import java.util.HashSet;
@@ -70,18 +68,11 @@ import jogamp.opengl.GLContextImpl;
public abstract class GLContext {
public static final boolean DEBUG = Debug.debug("GLContext");
- public static final boolean TRACE_SWITCH;
+ public static final boolean TRACE_SWITCH = Debug.isPropertyDefined("jogl.debug.GLContext.TraceSwitch", true);
/** Reflects property jogl.debug.DebugGL. If true, the debug pipeline is enabled at context creation. */
- public final static boolean DEBUG_GL;
+ public final static boolean DEBUG_GL = Debug.isPropertyDefined("jogl.debug.DebugGL", true);
/** Reflects property jogl.debug.TraceGL. If true, the trace pipeline is enabled at context creation. */
- public final static boolean TRACE_GL;
-
- static {
- final AccessControlContext acl = AccessController.getContext();
- DEBUG_GL = Debug.isPropertyDefined("jogl.debug.DebugGL", true, acl);
- TRACE_GL = Debug.isPropertyDefined("jogl.debug.TraceGL", true, acl);
- TRACE_SWITCH = Debug.isPropertyDefined("jogl.debug.GLContext.TraceSwitch", true, acl);
- }
+ public final static boolean TRACE_GL = Debug.isPropertyDefined("jogl.debug.TraceGL", true);
/** Indicates that the context was not made current during the last call to {@link #makeCurrent makeCurrent}. */
public static final int CONTEXT_NOT_CURRENT = 0;
diff --git a/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java b/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java
index 26abc53ba..1093685d6 100644
--- a/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java
+++ b/src/jogl/classes/javax/media/opengl/GLDrawableFactory.java
@@ -46,7 +46,6 @@ import java.util.ArrayList;
import java.util.List;
import com.jogamp.common.JogampRuntimeException;
-import jogamp.common.Debug;
import com.jogamp.common.util.ReflectionUtil;
@@ -56,6 +55,8 @@ import javax.media.nativewindow.NativeWindowFactory;
import javax.media.nativewindow.ProxySurface;
import javax.media.opengl.GLProfile.ShutdownType;
+import jogamp.opengl.Debug;
+
/** <P> Provides a virtual machine- and operating system-independent
mechanism for creating {@link GLDrawable}s. </P>
@@ -122,7 +123,7 @@ public abstract class GLDrawableFactory {
final String nativeOSType = NativeWindowFactory.getNativeWindowType(true);
GLDrawableFactory tmp = null;
- String factoryClassName = Debug.getProperty("jogl.gldrawablefactory.class.name", true, AccessController.getContext());
+ String factoryClassName = Debug.getProperty("jogl.gldrawablefactory.class.name", true);
ClassLoader cl = GLDrawableFactory.class.getClassLoader();
if (null == factoryClassName) {
if ( nativeOSType.equals(NativeWindowFactory.TYPE_X11) ) {
diff --git a/src/jogl/classes/javax/media/opengl/awt/GLJPanel.java b/src/jogl/classes/javax/media/opengl/awt/GLJPanel.java
index 85ffae63e..b30525c95 100644
--- a/src/jogl/classes/javax/media/opengl/awt/GLJPanel.java
+++ b/src/jogl/classes/javax/media/opengl/awt/GLJPanel.java
@@ -43,8 +43,6 @@ package javax.media.opengl.awt;
import java.nio.ByteBuffer;
import java.nio.IntBuffer;
import java.beans.Beans;
-import java.security.AccessControlContext;
-import java.security.AccessController;
import java.awt.Color;
import java.awt.EventQueue;
@@ -154,22 +152,20 @@ public class GLJPanel extends JPanel implements AWTGLAutoDrawable, WindowClosing
// Used by all backends either directly or indirectly to hook up callbacks
private Updater updater = new Updater();
- private static final AccessControlContext localACC = AccessController.getContext();
-
// Turns off the pbuffer-based backend (used by default, unless the
// Java 2D / OpenGL pipeline is in use)
private static boolean hardwareAccelerationDisabled =
- Debug.isPropertyDefined("jogl.gljpanel.nohw", true, localACC);
+ Debug.isPropertyDefined("jogl.gljpanel.nohw", true);
// Turns off the fallback to software-based rendering from
// pbuffer-based rendering
private static boolean softwareRenderingDisabled =
- Debug.isPropertyDefined("jogl.gljpanel.nosw", true, localACC);
+ Debug.isPropertyDefined("jogl.gljpanel.nosw", true);
// Indicates whether the Java 2D OpenGL pipeline is enabled
private boolean oglPipelineEnabled =
Java2D.isOGLPipelineActive() &&
- !Debug.isPropertyDefined("jogl.gljpanel.noogl", true, localACC);
+ !Debug.isPropertyDefined("jogl.gljpanel.noogl", true);
// For handling reshape events lazily
// private int reshapeX;