summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-03-27 00:35:42 +0100
committerSven Gothel <[email protected]>2011-03-27 00:35:42 +0100
commit4c37cbf64440ee1e3986afff94b74b513bed2bab (patch)
treeb2524c3f66fa932cd0d3fe4becde312dc7961522
parentc4aef6e1f9e118fd8d0df9b2e49e1a0d2dbb4f19 (diff)
JAWTUtil: Just use 'sunToolkitClass' in local block
-rw-r--r--src/nativewindow/classes/jogamp/nativewindow/jawt/JAWTUtil.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/nativewindow/classes/jogamp/nativewindow/jawt/JAWTUtil.java b/src/nativewindow/classes/jogamp/nativewindow/jawt/JAWTUtil.java
index 044f02dca..c1c97eece 100644
--- a/src/nativewindow/classes/jogamp/nativewindow/jawt/JAWTUtil.java
+++ b/src/nativewindow/classes/jogamp/nativewindow/jawt/JAWTUtil.java
@@ -60,7 +60,6 @@ public class JAWTUtil {
private static final Method isQueueFlusherThread;
private static final boolean j2dExist;
- private static final Class sunToolkitClass;
private static final Method sunToolkitAWTLockMethod;
private static final Method sunToolkitAWTUnlockMethod;
private static final boolean hasSunToolkitAWTLock;
@@ -71,7 +70,6 @@ public class JAWTUtil {
PrivilegedDataBlob1() {
ok = false;
}
- Class sunToolkitClass;
Method sunToolkitAWTLockMethod;
Method sunToolkitAWTUnlockMethod;
boolean ok;
@@ -101,10 +99,10 @@ public class JAWTUtil {
public Object run() {
PrivilegedDataBlob1 d = new PrivilegedDataBlob1();
try {
- d.sunToolkitClass = Class.forName("sun.awt.SunToolkit");
- d.sunToolkitAWTLockMethod = d.sunToolkitClass.getDeclaredMethod("awtLock", new Class[]{});
+ final Class sunToolkitClass = Class.forName("sun.awt.SunToolkit");
+ d.sunToolkitAWTLockMethod = sunToolkitClass.getDeclaredMethod("awtLock", new Class[]{});
d.sunToolkitAWTLockMethod.setAccessible(true);
- d.sunToolkitAWTUnlockMethod = d.sunToolkitClass.getDeclaredMethod("awtUnlock", new Class[]{});
+ d.sunToolkitAWTUnlockMethod = sunToolkitClass.getDeclaredMethod("awtUnlock", new Class[]{});
d.sunToolkitAWTUnlockMethod.setAccessible(true);
d.ok=true;
} catch (Exception e) {
@@ -113,7 +111,6 @@ public class JAWTUtil {
return d;
}
});
- sunToolkitClass = pdb1.sunToolkitClass;
sunToolkitAWTLockMethod = pdb1.sunToolkitAWTLockMethod;
sunToolkitAWTUnlockMethod = pdb1.sunToolkitAWTUnlockMethod;