131 * Calling add(3a, 3, 7) results in:<PRE>
132 * 5a, 5b, 5z, 5c, 5x, 3a, 2a, 2b, 2c, 1a </PRE>
133 *
134 * Using normal paint/event mechanics results in 1a appearing at the bottom
135 * and 5a being above all other components.
136 * <p>
137 * <b>Note:</b> that these layers are simply a logical construct and LayoutManagers
138 * will affect all child components of this container without regard for
139 * layer settings.
140 * <p>
141 * <strong>Warning:</strong> Swing is not thread safe. For more
142 * information see <a
143 * href="package-summary.html#threading">Swing's Threading
144 * Policy</a>.
145 * <p>
146 * <strong>Warning:</strong>
147 * Serialized objects of this class will not be compatible with
148 * future Swing releases. The current serialization support is
149 * appropriate for short term storage or RMI between applications running
150 * the same version of Swing. As of 1.4, support for long term storage
151 * of all JavaBeans™
152 * has been added to the <code>java.beans</code> package.
153 * Please see {@link java.beans.XMLEncoder}.
154 *
155 * @author David Kloba
156 * @since 1.2
157 */
158 @JavaBean(defaultProperty = "accessibleContext")
159 @SuppressWarnings("serial")
160 public class JLayeredPane extends JComponent implements Accessible {
161 /// Watch the values in getObjectForLayer()
162 /** Convenience object defining the Default layer. Equivalent to Integer.valueOf(0).*/
163 public static final Integer DEFAULT_LAYER = 0;
164 /** Convenience object defining the Palette layer. Equivalent to Integer.valueOf(100).*/
165 public static final Integer PALETTE_LAYER = 100;
166 /** Convenience object defining the Modal layer. Equivalent to Integer.valueOf(200).*/
167 public static final Integer MODAL_LAYER = 200;
168 /** Convenience object defining the Popup layer. Equivalent to Integer.valueOf(300).*/
169 public static final Integer POPUP_LAYER = 300;
170 /** Convenience object defining the Drag layer. Equivalent to Integer.valueOf(400).*/
171 public static final Integer DRAG_LAYER = 400;
742 */
743 @BeanProperty(bound = false)
744 public AccessibleContext getAccessibleContext() {
745 if (accessibleContext == null) {
746 accessibleContext = new AccessibleJLayeredPane();
747 }
748 return accessibleContext;
749 }
750
751 /**
752 * This class implements accessibility support for the
753 * <code>JLayeredPane</code> class. It provides an implementation of the
754 * Java Accessibility API appropriate to layered pane user-interface
755 * elements.
756 * <p>
757 * <strong>Warning:</strong>
758 * Serialized objects of this class will not be compatible with
759 * future Swing releases. The current serialization support is
760 * appropriate for short term storage or RMI between applications running
761 * the same version of Swing. As of 1.4, support for long term storage
762 * of all JavaBeans™
763 * has been added to the <code>java.beans</code> package.
764 * Please see {@link java.beans.XMLEncoder}.
765 */
766 @SuppressWarnings("serial")
767 protected class AccessibleJLayeredPane extends AccessibleJComponent {
768
769 /**
770 * Get the role of this object.
771 *
772 * @return an instance of AccessibleRole describing the role of the
773 * object
774 * @see AccessibleRole
775 */
776 public AccessibleRole getAccessibleRole() {
777 return AccessibleRole.LAYERED_PANE;
778 }
779 }
780 }
|
131 * Calling add(3a, 3, 7) results in:<PRE>
132 * 5a, 5b, 5z, 5c, 5x, 3a, 2a, 2b, 2c, 1a </PRE>
133 *
134 * Using normal paint/event mechanics results in 1a appearing at the bottom
135 * and 5a being above all other components.
136 * <p>
137 * <b>Note:</b> that these layers are simply a logical construct and LayoutManagers
138 * will affect all child components of this container without regard for
139 * layer settings.
140 * <p>
141 * <strong>Warning:</strong> Swing is not thread safe. For more
142 * information see <a
143 * href="package-summary.html#threading">Swing's Threading
144 * Policy</a>.
145 * <p>
146 * <strong>Warning:</strong>
147 * Serialized objects of this class will not be compatible with
148 * future Swing releases. The current serialization support is
149 * appropriate for short term storage or RMI between applications running
150 * the same version of Swing. As of 1.4, support for long term storage
151 * of all JavaBeans
152 * has been added to the <code>java.beans</code> package.
153 * Please see {@link java.beans.XMLEncoder}.
154 *
155 * @author David Kloba
156 * @since 1.2
157 */
158 @JavaBean(defaultProperty = "accessibleContext")
159 @SuppressWarnings("serial")
160 public class JLayeredPane extends JComponent implements Accessible {
161 /// Watch the values in getObjectForLayer()
162 /** Convenience object defining the Default layer. Equivalent to Integer.valueOf(0).*/
163 public static final Integer DEFAULT_LAYER = 0;
164 /** Convenience object defining the Palette layer. Equivalent to Integer.valueOf(100).*/
165 public static final Integer PALETTE_LAYER = 100;
166 /** Convenience object defining the Modal layer. Equivalent to Integer.valueOf(200).*/
167 public static final Integer MODAL_LAYER = 200;
168 /** Convenience object defining the Popup layer. Equivalent to Integer.valueOf(300).*/
169 public static final Integer POPUP_LAYER = 300;
170 /** Convenience object defining the Drag layer. Equivalent to Integer.valueOf(400).*/
171 public static final Integer DRAG_LAYER = 400;
742 */
743 @BeanProperty(bound = false)
744 public AccessibleContext getAccessibleContext() {
745 if (accessibleContext == null) {
746 accessibleContext = new AccessibleJLayeredPane();
747 }
748 return accessibleContext;
749 }
750
751 /**
752 * This class implements accessibility support for the
753 * <code>JLayeredPane</code> class. It provides an implementation of the
754 * Java Accessibility API appropriate to layered pane user-interface
755 * elements.
756 * <p>
757 * <strong>Warning:</strong>
758 * Serialized objects of this class will not be compatible with
759 * future Swing releases. The current serialization support is
760 * appropriate for short term storage or RMI between applications running
761 * the same version of Swing. As of 1.4, support for long term storage
762 * of all JavaBeans
763 * has been added to the <code>java.beans</code> package.
764 * Please see {@link java.beans.XMLEncoder}.
765 */
766 @SuppressWarnings("serial")
767 protected class AccessibleJLayeredPane extends AccessibleJComponent {
768
769 /**
770 * Get the role of this object.
771 *
772 * @return an instance of AccessibleRole describing the role of the
773 * object
774 * @see AccessibleRole
775 */
776 public AccessibleRole getAccessibleRole() {
777 return AccessibleRole.LAYERED_PANE;
778 }
779 }
780 }
|