diff options
author | Sven Gothel <[email protected]> | 2010-04-24 05:11:29 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2010-04-24 05:11:29 +0200 |
commit | 1ad8c39df6b097c80ba7a85badf555e7f669cc3f (patch) | |
tree | 740606f85dafdef5d5958498b080873c7bf188dd /src/jogl/classes/javax/media/opengl/GLContext.java | |
parent | 778225504c00c7ca03386b6eabfbda929542130f (diff) |
NEWT/AWT Interoperability
- Moved all event classes to
com.jogamp.newt.event
and the new AWT event helper to
com.jogamp.newt.awt.event
- Added Newt<Type>Adapter for convenience
- Added AWT<Type>Adapter for
- Using AWT agnostic NEWT event listener
see com.jogamp.test.junit.jogl.demos.gl2.gears.TestGearsNEWT
even for AWT
see com.jogamp.test.junit.jogl.demos.gl2.gears.TestGearsAWT
(Nice idea by mbien)
- Forwarding AWT events to NEWT (refactoring)
Misc
- GLDrawableFactory.shutdown() is now protected and called
by the JVM shutdown hook. Hence removing the validate().
Diffstat (limited to 'src/jogl/classes/javax/media/opengl/GLContext.java')
-rw-r--r-- | src/jogl/classes/javax/media/opengl/GLContext.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/jogl/classes/javax/media/opengl/GLContext.java b/src/jogl/classes/javax/media/opengl/GLContext.java index 2709dd506..c07bbeaf4 100644 --- a/src/jogl/classes/javax/media/opengl/GLContext.java +++ b/src/jogl/classes/javax/media/opengl/GLContext.java @@ -188,6 +188,13 @@ public abstract class GLContext { } /** + * @return true if this GLContext is current on this thread + */ + public final boolean isCurrent() { + return getCurrent() == this ; + } + + /** * Sets the thread-local variable returned by {@link #getCurrent} * and has no other side-effects. For use by third parties adding * new GLContext implementations; not for use by end users. |