-
Bug
-
Resolution: Fixed
-
P4
-
1.3.0, 1.3.1
-
beta
-
x86
-
windows_nt, windows_2000
Name: jk109818 Date: 06/22/2000
java version "1.3.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)
The problem appears after setting the maximum size of
a JInternalFrame to its original size. (JDK1.3, Win NT4)
When you try to resize the InternalFrame to a greater size, which shoud
not be possible with the setMaximunSize property, the frame
grows up by doubling instantly its size.
The program rises no exception.
Here is a sample code reproducing this bug :
import javax.swing.*;
import java.awt.*;
public class testInternalFrame extends JFrame {
public static void main(String[] args) {
testInternalFrame ti = new testInternalFrame();
ti.setSize(300,300);
ti.setVisible(true);
}
public testInternalFrame() {
super();
JDesktopPane j = new JDesktopPane();
getContentPane().setLayout(new BorderLayout());
JInternalFrame jif = new JInternalFrame();
j.add(jif);
jif.setResizable(true); jif.setClosable(true); jif.setIconifiable(true);
jif.setSize(100,100);
jif.setMaximumSize(jif.getSize());
jif.setVisible(true);
getContentPane().add(j,BorderLayout.CENTER);
}
}
I found no workaround for this bug, any help will be appreciated.
Note that this bug exists with the JDK1.2 for windows NT4 too.
(Review ID: 105387)
======================================================================