Minimize icon instead of restore in Windows L&F
Hi. The following code shows a simple JInternalFrame in a JDesktop applet. When minimizing the JInternalFrame notice the icon of the frame still shows MINIMIZE and not RESTORE.
Any fixes/comments?
Thanks.
import javax.swing.*;
public class Tap2 extends javax.swing.JApplet{
public Tap2() {
try
{
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName ());
}
catch (Exception exc)
{
System.err.println("Error loading L&F: " + exc);
}
JDesktopPane dk = new JDesktopPane();
setContentPane(dk);
setBounds(10,10,400,400);
MyInf inf = new MyInf();
dk.add(inf);
inf.setVisible(true);
dk.setVisible(true);
}
public void init(){
}
class MyInf extends JInternalFrame{
public MyInf(){
super("X",false,false,false,
true);//iconifiable
setSize(300,300);
setLocation(20, 20);
}
}
}

