-
Bug
-
Resolution: Duplicate
-
P4
-
None
-
1.2.0
-
sparc
-
solaris_2.5.1
Name: dgC58589 Date: 01/21/98
Resizing a Frame with the mouse does not change the values returned by getBounds()
public class testFrame extends Frame
{
private int height=100,width=100;
public testFrame()
{
Rectangle loc;
loc=getBounds();
System.out.println("x="+loc.x+" y="+loc.y+
" width="+loc.width+" height="+loc.height);
setSize(width,height);
show();
}
public void paint(Graphics g)
{
Rectangle loc;
loc=getBounds();
System.out.println("x="+loc.x+" y="+loc.y+
" width="+loc.width+" height="+loc.height);
}
public static void main(String[] args)
{
testFrame frame= new testFrame();
}
}
When run with JDK1.1.5 Solaris this program results in changing values
when making the Frame window bigger. With the JDK1.2beta2, the values stay
at the initial value. Is this a bug , or a change in API behavior????
(Review ID: 23586)
======================================================================
- duplicates
-
JDK-4103095 Frame.getBounds() returns the wrong position after a resize.
-
- Closed
-