diff options
author | Sven Gothel <[email protected]> | 2014-07-08 21:09:30 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2014-07-08 21:09:30 +0200 |
commit | a41db57df54863566b0e286cd100bbbc5518eb7f (patch) | |
tree | fb82077e79f54ba2fcf4c77b42458572fd9995eb /src/jogl/classes/javax/media | |
parent | b740161d456c059d1b51029c603ce144eb2b2d44 (diff) |
Findbugs: Use <NumberType>.valueOf(..) instead of 'new <NumberType>(..)'
Diffstat (limited to 'src/jogl/classes/javax/media')
-rw-r--r-- | src/jogl/classes/javax/media/opengl/GLContext.java | 2 | ||||
-rw-r--r-- | src/jogl/classes/javax/media/opengl/GLUniformData.java | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/jogl/classes/javax/media/opengl/GLContext.java b/src/jogl/classes/javax/media/opengl/GLContext.java index 16399799f..e4e29ee2b 100644 --- a/src/jogl/classes/javax/media/opengl/GLContext.java +++ b/src/jogl/classes/javax/media/opengl/GLContext.java @@ -1611,7 +1611,7 @@ public abstract class GLContext { // Thread.dumpStack(); } final String objectKey = getDeviceVersionAvailableKey(device, reqMajor, profile); - final Integer val = new Integer(composeBits(resMajor, resMinor, resCtp)); + final Integer val = Integer.valueOf(composeBits(resMajor, resMinor, resCtp)); synchronized(deviceVersionAvailable) { return deviceVersionAvailable.put( objectKey, val ); } diff --git a/src/jogl/classes/javax/media/opengl/GLUniformData.java b/src/jogl/classes/javax/media/opengl/GLUniformData.java index 67cc4c999..47f07539b 100644 --- a/src/jogl/classes/javax/media/opengl/GLUniformData.java +++ b/src/jogl/classes/javax/media/opengl/GLUniformData.java @@ -15,7 +15,7 @@ public class GLUniformData { * */ public GLUniformData(final String name, final int val) { - initScalar(name, 1, new Integer(val)); + initScalar(name, 1, Integer.valueOf(val)); } /** @@ -25,7 +25,7 @@ public class GLUniformData { * */ public GLUniformData(final String name, final float val) { - initScalar(name, 1, new Float(val)); + initScalar(name, 1, Float.valueOf(val)); } /** @@ -74,8 +74,8 @@ public class GLUniformData { initBuffer(name, rows, columns, data); } - public GLUniformData setData(final int data) { initScalar(new Integer(data)); return this; } - public GLUniformData setData(final float data) { initScalar(new Float(data)); return this; } + public GLUniformData setData(final int data) { initScalar(Integer.valueOf(data)); return this; } + public GLUniformData setData(final float data) { initScalar(Float.valueOf(data)); return this; } public GLUniformData setData(final IntBuffer data) { initBuffer(data); return this; } public GLUniformData setData(final FloatBuffer data) { initBuffer(data); return this; } |