A couple of fixes for the JLayeredPane. This fixes the behaviour of
toFront(), toBack(), setPosition() and setLayer() which was slightly
broken before.
2006-06-23 Roman Kennke <[EMAIL PROTECTED]>
* javax/swing/JLayeredPane.java
(getPosition): Moved code around to avoid unnecessa
I have essentially rewritten most of JLayeredPane. I noticed some
troubles with this class and read a little in the OReilly Swing book 1st
edition. I learned that we did a couple of things wrong in this class:
- we stored all components and their layers in the Hashtable. This is
wrong. JComponents
The attached patch fixes two issues with JLayeredPane. It avoids a
potential memory leak that comes from not overriding removeAll in
JLayeredPane. Calling removeAll() would cause components to be removed
but their layer information to be kept forever in JLayeredPane's
Hashtable.
Also, I improved t
This fixes a mauve test for JLayeredPane. In order to fix this, I
implemented the set/getComponentZOrder() methods in Container and made
JLayeredPane use these methods. This is not only much more efficient
than adding/removing components when changing the order, it also fixes a
nasty problem when t