Pessoal,
Como faço para chamar uma classe (por exemplo um formulario) dentro do JInternalFrame?
Segue:
new ActionListener() // anonymous inner class
{
// display new internal window
public void actionPerformed( ActionEvent event )
{
// create internal frame
JInternalFrame frame = new JInternalFrame("Frame Interno", true, true, true,true);
//JInternalFrame frame = new JInternalFrame();
MyJPanel panel = new MyJPanel(); // create new panel
frame.add( panel, BorderLayout.CENTER ); // add panel
frame.pack(); // set internal frame to size of contents
theDesktop.add( frame ); // attach internal frame
try {
frame.setMaximum(true);
frame.setSelected(true);
} catch (PropertyVetoException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
frame.setVisible( true ); // show internal frame
} // end method actionPerformed
} // end anonymous inner class
); // end call to addActionListener
} // end constructor DesktopFr