-
Bug
-
Resolution: Fixed
-
P2
-
1.4.0
-
None
-
beta
-
sparc
-
solaris_7
-
Verified
I have attached a simple test case of this. It consists of a frame with two buttons and a subclass of Component. One button can be clicked to move the frame (setBounds), and the other will invoke repaint on the Frame to cause the Component to repaint. The Component displays an integer that is incremented everytime it is messaged with paint. If you click on the repaint button you can see that the Component updates its display. If you click on the move button, then the repaint button you'll notice that the repaints stop happening. Further, update/paint is never invoked on the Frame, which is why the Component is never messaged to paint. You can cause the repainting to occur again by obscuring the Window, or clicking on another Window and then back on the java Frame, then the repainting will work again.
This is with 1.4beta-B43.
I tracked this down a little, and it appears that MComponentPeer is assuming PaintEvent.PAINT will be dispatched after setBounds is invoked, which doesn't appear to be the case if the size of the Component doesn't change in setBounds. This change appears to have been introduced in 1.143 of MComponentPeer.
This is with 1.4beta-B43.
I tracked this down a little, and it appears that MComponentPeer is assuming PaintEvent.PAINT will be dispatched after setBounds is invoked, which doesn't appear to be the case if the size of the Component doesn't change in setBounds. This change appears to have been introduced in 1.143 of MComponentPeer.
- relates to
-
JDK-4424838 Repaint problems in 1.4 build 54 with BarChart and SpreadSheet demos
-
- Resolved
-
-
JDK-4267393 Repaint twice
-
- Resolved
-