aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorpaulby <[email protected]>2005-02-11 21:12:36 +0000
committerpaulby <[email protected]>2005-02-11 21:12:36 +0000
commitd5602c854548a67bf11adf339a5f87cd3bce5505 (patch)
tree40916aaa0091ec2aba79bb8936c3f7e1b96eafd5 /src
parent4244bac82ed473b2af6398c939b15cb8b1e74168 (diff)
Fix issue 102, thanks Alessandro
Issue number: 102 Obtained from: aces Submitted by: paulby Reviewed by: kcr git-svn-id: https://svn.java.net/svn/j3d-core~svn/trunk@119 ba19aa83-45c5-6ac9-afd3-db810772062c
Diffstat (limited to 'src')
-rw-r--r--src/classes/share/javax/media/j3d/Canvas3D.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/classes/share/javax/media/j3d/Canvas3D.java b/src/classes/share/javax/media/j3d/Canvas3D.java
index 86f5316..4261c1f 100644
--- a/src/classes/share/javax/media/j3d/Canvas3D.java
+++ b/src/classes/share/javax/media/j3d/Canvas3D.java
@@ -927,7 +927,7 @@ public class Canvas3D extends Canvas {
CanvasViewEventCatcher canvasViewEventCatcher;
// The parent window for this canvas.
- Container parent;
+ private Container parent;
// flag that indicates if light has changed
boolean lightChanged = false;
@@ -1495,6 +1495,11 @@ public class Canvas3D extends Canvas {
if (rdr != null) {
rdr.userStop = false;
}
+
+ // Fix for issue 102 removing strong reference and avoiding memory leak
+ // due retention of parent container
+
+ this.parent = null;
}
// This decides if the canvas is active