aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/com
diff options
context:
space:
mode:
Diffstat (limited to 'src/jogl/classes/com')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/GLAutoDrawableDelegate.java5
-rw-r--r--src/jogl/classes/com/jogamp/opengl/swt/GLCanvas.java7
-rw-r--r--src/jogl/classes/com/jogamp/opengl/util/GLDrawableUtil.java2
3 files changed, 3 insertions, 11 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/GLAutoDrawableDelegate.java b/src/jogl/classes/com/jogamp/opengl/GLAutoDrawableDelegate.java
index 0f0f03ac4..bec05a0bd 100644
--- a/src/jogl/classes/com/jogamp/opengl/GLAutoDrawableDelegate.java
+++ b/src/jogl/classes/com/jogamp/opengl/GLAutoDrawableDelegate.java
@@ -170,11 +170,6 @@ public class GLAutoDrawableDelegate extends GLAutoDrawableBase implements GLAuto
}
@Override
- public final void setRealized(boolean realized) {
- drawable.setRealized(realized);
- }
-
- @Override
public final void swapBuffers() throws GLException {
defaultSwapBuffers();
}
diff --git a/src/jogl/classes/com/jogamp/opengl/swt/GLCanvas.java b/src/jogl/classes/com/jogamp/opengl/swt/GLCanvas.java
index 80e1aa80d..169266152 100644
--- a/src/jogl/classes/com/jogamp/opengl/swt/GLCanvas.java
+++ b/src/jogl/classes/com/jogamp/opengl/swt/GLCanvas.java
@@ -705,16 +705,13 @@ public class GLCanvas extends Canvas implements GLAutoDrawable {
}
@Override
- public GLContext setContext(GLContext newCtx) {
+ public GLContext setContext(GLContext newCtx, boolean destroyPrevCtx) {
final RecursiveLock _lock = lock;
_lock.lock();
try {
final GLContext oldCtx = context;
- final boolean newCtxCurrent = GLDrawableHelper.switchContext(drawable, oldCtx, newCtx, additionalCtxCreationFlags);
+ GLDrawableHelper.switchContext(drawable, oldCtx, destroyPrevCtx, newCtx, additionalCtxCreationFlags);
context=(GLContextImpl)newCtx;
- if(newCtxCurrent) {
- context.makeCurrent();
- }
return oldCtx;
} finally {
_lock.unlock();
diff --git a/src/jogl/classes/com/jogamp/opengl/util/GLDrawableUtil.java b/src/jogl/classes/com/jogamp/opengl/util/GLDrawableUtil.java
index c03e4bfa4..83414ddb0 100644
--- a/src/jogl/classes/com/jogamp/opengl/util/GLDrawableUtil.java
+++ b/src/jogl/classes/com/jogamp/opengl/util/GLDrawableUtil.java
@@ -151,7 +151,7 @@ public class GLDrawableUtil {
for(int i = dest.getGLEventListenerCount() - 1; 0 <= i; i--) {
dest.disposeGLEventListener(dest.getGLEventListener(i), false);
}
- dest.setContext( src.setContext( dest.getContext() ) );
+ dest.setContext( src.setContext( dest.getContext(), false ), false );
src.invoke(true, GLEventListenerState.setViewport);
dest.invoke(true, GLEventListenerState.setViewport);