Login  Register

Re: JTabbedPane Canvas3D bug

Posted by Sven Gothel on Dec 20, 2013; 7:54pm
URL: https://forum.jogamp.org/JTabbedPane-Canvas3D-bug-tp4030983p4031011.html

On 12/20/2013 07:19 PM, Julien [via jogamp] wrote:

> Sven and Julien,
>
> Thanks for looking into this. I downloaded the latest nightly autobuild
> (version=2.1.4-rc-20131219). (This project has nice continuous integration,
> BTW. Nice work). I note that the "stuck" image problem I describe above is
> fixed, but I encountered another problem. The code I submit here is almost the
> same as the code sample above, but the constructor is slightly different. In
> particular, the layout is changing from BorderLayout to BoxLayout for tab 1
> and 2. Now after switching back and forth between tabs, the image eventually
> disappears on the second tab. (I had actually noticed this same problem in an
> earlier version of jogamp). This example works on Java 3D 1.5 / Java 6 / OS X.
>
Since I don't test Java3D,
can you validate w/ our JOGL unit tests:

com.jogamp.opengl.test.junit.jogl.awt.TestBug816JTabbedPanelVisibilityB849B878AWT
com.jogamp.opengl.test.junit.jogl.awt.TestBug816GLCanvasFrameHoppingB849B889AWT

You may use scripts/tests.sh and tests-osx-x64.sh:
  cd jogl/make
  edit scripts/tests.sh <- enable one of the unit test
  edit scripts/tests-osx-x64.sh <- match your folders, i.e. 'build' path
  run tests-osx-x64.sh

Here both tests work fine.

Pls reply w/ your results .. thank you!

~Sven

>     public Bug() {
>         super(new GridLayout(1, 1));
>         JTabbedPane tabbedPane = new JTabbedPane();
>         JPanel      jp1        = new JPanel();
>         jp1.setLayout(new BorderLayout());
>         jp1.add(canvas3d(1.0f, 1.0f, 1.0f));
>         JPanel jp2 = new JPanel();
>         jp2.setLayout(new BoxLayout(jp2, BoxLayout.X_AXIS));
>         jp2.add(canvas3d(1.0f, 1.0f, 1.0f));
>         tabbedPane.addTab("Tab 1", jp1);
>         tabbedPane.addTab("Tab 2", jp2);
>         add(tabbedPane);
>     }
>
> Thanks again.
>
> -Julien


signature.asc (911 bytes) Download Attachment