diff options
author | Sven Gothel <[email protected]> | 2012-06-27 05:05:36 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2012-06-27 05:05:36 +0200 |
commit | a06e40cce89615eb8c4b080842997c9c3ad1130b (patch) | |
tree | 0bac563f3604662f8583b4f0da21b68ac53abd28 /src/jogl/classes/jogamp/opengl/GLContextImpl.java | |
parent | 4a0a5d69ffcb7592b092991ddb3761653c389ce6 (diff) |
NativeSurface Cleanup (API Change) - Adapt to GlueGen Lock cleanup commit: 834b9e530e652b7ff7c5e222720bce3ad2b11c5f
- adapt to GlueGen Lock cleanup
- remove isSurfaceLocked(), use 'null != getSurfaceLockOwner()' instead
Misc:
- remove unused priv./impl. methods
- add @Override
Diffstat (limited to 'src/jogl/classes/jogamp/opengl/GLContextImpl.java')
-rw-r--r-- | src/jogl/classes/jogamp/opengl/GLContextImpl.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/jogl/classes/jogamp/opengl/GLContextImpl.java b/src/jogl/classes/jogamp/opengl/GLContextImpl.java index 51201b3a9..ff1b65520 100644 --- a/src/jogl/classes/jogamp/opengl/GLContextImpl.java +++ b/src/jogl/classes/jogamp/opengl/GLContextImpl.java @@ -164,7 +164,7 @@ public abstract class GLContextImpl extends GLContext { if(null!=read && drawable!=read && !isGLReadDrawableAvailable()) { throw new GLException("GL Read Drawable not available"); } - boolean lockHeld = lock.isOwner(); + final boolean lockHeld = lock.isOwner(Thread.currentThread()); if(lockHeld) { release(); } @@ -224,8 +224,8 @@ public abstract class GLContextImpl extends GLContext { if(TRACE_SWITCH) { System.err.println(getThreadName() +": GLContext.ContextSwitch: - release() - force: "+force+", "+lock); } - if ( !lock.isOwner() ) { - throw new GLException("Context not current on current thread "+Thread.currentThread().getName()+": "+this); + if ( !lock.isOwner(Thread.currentThread()) ) { + throw new GLException("Context not current on current thread "+Thread.currentThread().getName()+": "+this); } final boolean actualRelease = force || lock.getHoldCount() == 1 ; try { |