summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChien Yang <[email protected]>2007-01-07 01:43:42 +0000
committerChien Yang <[email protected]>2007-01-07 01:43:42 +0000
commit7b35e61db0e13dca17ac68ec0e180e5a20fd721d (patch)
treed8ec3f02584b2bfdcd57a26feca9ba1d2c6fcc1c
parent46be2e6a0d020a192801b404c99200c35643302a (diff)
Fixed Issue 433 : JCanvas3D crashed when using jogl pipe.
git-svn-id: https://svn.java.net/svn/j3d-core-utils~svn/trunk@146 9497e636-51bd-65ba-982d-a4982e1767a5
-rw-r--r--src/classes/share/com/sun/j3d/exp/swing/JCanvas3D.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/classes/share/com/sun/j3d/exp/swing/JCanvas3D.java b/src/classes/share/com/sun/j3d/exp/swing/JCanvas3D.java
index 6662e80..b8dfd64 100644
--- a/src/classes/share/com/sun/j3d/exp/swing/JCanvas3D.java
+++ b/src/classes/share/com/sun/j3d/exp/swing/JCanvas3D.java
@@ -278,7 +278,8 @@ public class JCanvas3D extends JPanel implements AncestorListener {
* Computes the physical dimensions of the screen in space.
*/
private void computePhysicalDimensions() {
- Rectangle screenRect = canvas.getGraphicsConfiguration().getBounds();
+ // Fix to Issue : 433 - JCanvas3D crashed when using jogl pipe.
+ Rectangle screenRect = this.graphicsConfig.getBounds();
int screenWidth = (int) screenRect.getWidth();
int screenHeight = (int) screenRect.getHeight();
canvas.getScreen3D().setSize(screenWidth, screenHeight);