From ebed9f0322e2a2279a525e04ee3875c9034a7f45 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 16 Nov 2013 05:00:27 +0100 Subject: Bug 906 - JAWTWindow Component- and HierarchyListener must be detached at JAWTWindow.destroy() - GLCanvas Recreation Case In case a JAWTWindow owner recreates itself, destroying JAWTWindow must detach the Component- and HierarchyListener from the AWT component! Test TestBug816GLCanvasFrameHoppingB849B889AWT shows properly detaching listener at jawtWindow destruction. --- src/jogl/classes/javax/media/opengl/awt/GLCanvas.java | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/jogl/classes') diff --git a/src/jogl/classes/javax/media/opengl/awt/GLCanvas.java b/src/jogl/classes/javax/media/opengl/awt/GLCanvas.java index 01d6a6738..36c0144a9 100644 --- a/src/jogl/classes/javax/media/opengl/awt/GLCanvas.java +++ b/src/jogl/classes/javax/media/opengl/awt/GLCanvas.java @@ -583,6 +583,15 @@ public class GLCanvas extends Canvas implements AWTGLAutoDrawable, WindowClosing } } + @Override + public void setVisible(boolean b) { + if(DEBUG) { + System.err.println(getThreadName()+": Info: setVisible("+b+")"); + Thread.dumpStack(); + } + super.setVisible(b); + } + /** Overridden to track when this component is added to a container. Subclasses which override this method must call super.addNotify() in their addNotify() method in order to -- cgit v1.2.3