Hi!
I have a JTabbedPane from which I want to drag out some tabs. When the
tab is dragged out of the JTabbedPane a JFrame should appear holding the
Component that was placed in the tab and the tab should be removed from
the JTabbedPane. The whole thing works except that the component is not
shown in the new JFrame. Here is the code I am using:
int index = getSelectedIndex();
if ( index < 0 ) {
return;
}
final Component comp = getComponentAt(index);
final String title = getTitleAt(index);
removeTabAt(index);
JFrame frame = new JFrame(title);
frame.getContentPane().add(comp);
frame.pack();
frame.show();
Doing this the tab is correctly removed. The new JFrame has also the
correct size for the Component, but the component does not show. Does
anybody know what I am doing wrong?
Thanks in advance
Michael
_______________________________________________
Advanced-swing mailing list
[EMAIL PROTECTED]
http://eos.dk/mailman/listinfo/advanced-swing