diff options
author | Sven Gothel <[email protected]> | 2014-01-11 07:27:15 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2014-01-11 07:27:15 +0100 |
commit | 6ea03078e162eed89653ae123d172b6fca7c6d61 (patch) | |
tree | 257f5298d499af876de1b8a4043d1f9fe10b9107 /src/jogl/classes | |
parent | 6647b4a63866a554c738e0b7b61e6dc40a6fb511 (diff) |
Misc Cleanup: JAWTWindow: Reusing visible in HIERARCHY listener; Remove obsolete 'getPrivateGraphicsConfiguration()'
Diffstat (limited to 'src/jogl/classes')
-rw-r--r-- | src/jogl/classes/jogamp/opengl/GLDrawableHelper.java | 10 | ||||
-rw-r--r-- | src/jogl/classes/jogamp/opengl/GLFBODrawableImpl.java | 4 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java b/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java index 61735c487..c0bf43d2c 100644 --- a/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java +++ b/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java @@ -336,7 +336,7 @@ public class GLDrawableHelper { } final NativeSurface ns = drawable.getNativeSurface(); final int lockRes = ns.lockSurface(); - if (NativeSurface.LOCK_SURFACE_NOT_READY >= lockRes) { + if ( NativeSurface.LOCK_SURFACE_NOT_READY >= lockRes ) { throw new NativeWindowException("Could not lock surface of drawable: "+drawable); } boolean validateSize = true; @@ -345,10 +345,10 @@ public class GLDrawableHelper { System.err.println("WARNING: Odd size detected: "+newWidth+"x"+newHeight+", using safe size 1x1. Drawable "+drawable); Thread.dumpStack(); } - if(0>=newWidth) { newWidth = 1; validateSize=false; } - if(0>=newHeight) { newHeight = 1; validateSize=false; } + if( 0 >= newWidth ) { newWidth = 1; validateSize=false; } + if( 0 >= newHeight ) { newHeight = 1; validateSize=false; } // propagate new size - if(ns instanceof ProxySurface) { + if( ns instanceof ProxySurface ) { final ProxySurface ps = (ProxySurface) ns; final UpstreamSurfaceHook ush = ps.getUpstreamSurfaceHook(); if(ush instanceof UpstreamSurfaceHook.MutableSize) { @@ -359,7 +359,7 @@ public class GLDrawableHelper { } else if(DEBUG) { // we have to assume surface contains the new size already, hence size check @ bottom System.err.println("GLDrawableHelper.resizeOffscreenDrawable: Drawable's offscreen surface n.a. ProxySurface, but "+ns.getClass().getName()+": "+ns); } - if(drawable instanceof GLFBODrawable) { + if( drawable instanceof GLFBODrawable ) { if( null != context && context.isCreated() ) { ((GLFBODrawable) drawable).resetSize(context.getGL()); } diff --git a/src/jogl/classes/jogamp/opengl/GLFBODrawableImpl.java b/src/jogl/classes/jogamp/opengl/GLFBODrawableImpl.java index ab318927c..0e9d142ba 100644 --- a/src/jogl/classes/jogamp/opengl/GLFBODrawableImpl.java +++ b/src/jogl/classes/jogamp/opengl/GLFBODrawableImpl.java @@ -90,7 +90,7 @@ public class GLFBODrawableImpl extends GLDrawableImpl implements GLFBODrawable { this.initialized = false; this.parent = parent; - this.origParentChosenCaps = (GLCapabilitiesImmutable) getChosenGLCapabilities(); // just to avoid null, will be reset at initialize(..) + this.origParentChosenCaps = getChosenGLCapabilities(); // just to avoid null, will be reset at initialize(..) this.texUnit = textureUnit; this.samples = fboCaps.getNumSamples(); fboResetQuirk = false; @@ -552,7 +552,7 @@ public class GLFBODrawableImpl extends GLDrawableImpl implements GLFBODrawable { ",\n\tfboI back "+fboIBack+", front "+fboIFront+", num "+(initialized ? fbos.length : 0)+ ",\n\tFBO front read "+getDefaultReadFramebuffer()+", "+getFBObject(GL.GL_FRONT)+ ",\n\tFBO back write "+getDefaultDrawFramebuffer()+", "+getFBObject(GL.GL_BACK)+ - ",\n\tSurface "+getNativeSurface()+ + ",\n\tSurface "+surface+ "]"; } |