Re: Problem changing SWT layout
Posted by
gouessej on
Oct 25, 2013; 1:47pm
URL: https://forum.jogamp.org/Problem-changing-SWT-layout-tp4030374p4030376.html
Hi
I was doing something similar several years ago, I used SWT_AWT to put an AWT GLCanvas into a SWT Composite but I didn't use a StackLayout. I think that the rendering is stopped when the GLCanvas is no longer on the top which is the expected behaviour.
However, in your case, you use Control.moveBelow(Control) which calls dispose() on the control passed as a parameter
and its children. This is neither a bug nor a problem concerning JOGL. I can't be 100% affirmative but this has probably nothing to do with the switch from JOGL 1 to JOGL 2.
If you want to avoid your canvas from being disposed, use another approach (maybe a StackLayout, a NEWT SWT canvas or JogAmp SWT OpenGL heavyweight canvas called GLCanvas too but in a different package).