< prev index next >
src/java.desktop/share/classes/javax/swing/JDesktopPane.java
Print this page
@@ -44,25 +44,25 @@
import java.util.Set;
import java.util.TreeSet;
import java.util.LinkedHashSet;
/**
* A container used to create a multiple-document interface or a virtual desktop.
- * You create <code>JInternalFrame</code> objects and add them to the
- * <code>JDesktopPane</code>. <code>JDesktopPane</code> extends
- * <code>JLayeredPane</code> to manage the potentially overlapping internal
+ * You create {@code JInternalFrame} objects and add them to the
+ * {@code JDesktopPane}. {@code JDesktopPane} extends
+ * {@code JLayeredPane} to manage the potentially overlapping internal
* frames. It also maintains a reference to an instance of
- * <code>DesktopManager</code> that is set by the UI
- * class for the current look and feel (L&F). Note that <code>JDesktopPane</code>
+ * {@code DesktopManager} that is set by the UI
+ * class for the current look and feel (L&F). Note that {@code JDesktopPane}
* does not support borders.
* <p>
- * This class is normally used as the parent of <code>JInternalFrames</code>
- * to provide a pluggable <code>DesktopManager</code> object to the
- * <code>JInternalFrames</code>. The <code>installUI</code> of the
+ * This class is normally used as the parent of {@code JInternalFrames}
+ * to provide a pluggable {@code DesktopManager} object to the
+ * {@code JInternalFrames}. The {@code installUI} of the
* L&F specific implementation is responsible for setting the
- * <code>desktopManager</code> variable appropriately.
- * When the parent of a <code>JInternalFrame</code> is a <code>JDesktopPane</code>,
- * it should delegate most of its behavior to the <code>desktopManager</code>
+ * {@code desktopManager} variable appropriately.
+ * When the parent of a {@code JInternalFrame} is a {@code JDesktopPane},
+ * it should delegate most of its behavior to the {@code desktopManager}
* (closing, resizing, etc).
* <p>
* For further documentation and examples see
* <a href="http://docs.oracle.com/javase/tutorial/uiswing/components/internalframe.html">How to Use Internal Frames</a>,
* a section in <em>The Java Tutorial</em>.
@@ -76,11 +76,11 @@
* Serialized objects of this class will not be compatible with
* future Swing releases. The current serialization support is
* appropriate for short term storage or RMI between applications running
* the same version of Swing. As of 1.4, support for long term storage
* of all JavaBeans™
- * has been added to the <code>java.beans</code> package.
+ * has been added to the {@code java.beans} package.
* Please see {@link java.beans.XMLEncoder}.
*
* @see JInternalFrame
* @see JInternalFrame.JDesktopIcon
* @see DesktopManager
@@ -124,11 +124,11 @@
private transient List<JInternalFrame> framesCache;
private boolean componentOrderCheckingEnabled = true;
private boolean componentOrderChanged = false;
/**
- * Creates a new <code>JDesktopPane</code>.
+ * Creates a new {@code JDesktopPane}.
*/
public JDesktopPane() {
setUIProperty("opaque", Boolean.TRUE);
setFocusCycleRoot(true);
@@ -149,11 +149,11 @@
}
/**
* Returns the L&F object that renders this component.
*
- * @return the <code>DesktopPaneUI</code> object that
+ * @return the {@code DesktopPaneUI} object that
* renders this component
*/
public DesktopPaneUI getUI() {
return (DesktopPaneUI)ui;
}
@@ -197,12 +197,12 @@
dragModeSet = true;
}
/**
* Gets the current "dragging style" used by the desktop pane.
- * @return either <code>Live_DRAG_MODE</code> or
- * <code>OUTLINE_DRAG_MODE</code>
+ * @return either {@code Live_DRAG_MODE} or
+ * {@code OUTLINE_DRAG_MODE}
* @see #setDragMode
* @since 1.3
*/
public int getDragMode() {
return dragMode;
@@ -218,15 +218,15 @@
public DesktopManager getDesktopManager() {
return desktopManager;
}
/**
- * Sets the <code>DesktopManger</code> that will handle
+ * Sets the {@code DesktopManger} that will handle
* desktop-specific UI actions. This may be overridden by
* {@code LookAndFeel}.
*
- * @param d the <code>DesktopManager</code> to use
+ * @param d the {@code DesktopManager} to use
*
* @beaninfo
* bound: true
* description: Desktop manager to handle the internal frames in the
* desktop pane.
@@ -236,13 +236,13 @@
desktopManager = d;
firePropertyChange("desktopManager", oldValue, desktopManager);
}
/**
- * Notification from the <code>UIManager</code> that the L&F has changed.
+ * Notification from the {@code UIManager} that the L&F has changed.
* Replaces the current UI object with the latest version from the
- * <code>UIManager</code>.
+ * {@code UIManager}.
*
* @see JComponent#updateUI
*/
public void updateUI() {
setUI((DesktopPaneUI)UIManager.getUI(this));
@@ -259,14 +259,14 @@
public String getUIClassID() {
return uiClassID;
}
/**
- * Returns all <code>JInternalFrames</code> currently displayed in the
+ * Returns all {@code JInternalFrames} currently displayed in the
* desktop. Returns iconified frames as well as expanded frames.
*
- * @return an array of <code>JInternalFrame</code> objects
+ * @return an array of {@code JInternalFrame} objects
*/
public JInternalFrame[] getAllFrames() {
return getAllFrames(this).toArray(new JInternalFrame[0]);
}
@@ -288,25 +288,25 @@
}
}
return results;
}
- /** Returns the currently active <code>JInternalFrame</code>
- * in this <code>JDesktopPane</code>, or <code>null</code>
- * if no <code>JInternalFrame</code> is currently active.
+ /** Returns the currently active {@code JInternalFrame}
+ * in this {@code JDesktopPane}, or {@code null}
+ * if no {@code JInternalFrame} is currently active.
*
- * @return the currently active <code>JInternalFrame</code> or
- * <code>null</code>
+ * @return the currently active {@code JInternalFrame} or
+ * {@code null}
* @since 1.3
*/
public JInternalFrame getSelectedFrame() {
return selectedFrame;
}
- /** Sets the currently active <code>JInternalFrame</code>
- * in this <code>JDesktopPane</code>. This method is used to bridge
+ /** Sets the currently active {@code JInternalFrame}
+ * in this {@code JDesktopPane}. This method is used to bridge
* the package gap between JDesktopPane and the platform implementation
* code and should not be called directly. To visually select the frame
* the client must call JInternalFrame.setSelected(true) to activate
* the frame.
* @see JInternalFrame#setSelected(boolean)
@@ -318,16 +318,16 @@
public void setSelectedFrame(JInternalFrame f) {
selectedFrame = f;
}
/**
- * Returns all <code>JInternalFrames</code> currently displayed in the
+ * Returns all {@code JInternalFrames} currently displayed in the
* specified layer of the desktop. Returns iconified frames as well
* expanded frames.
*
* @param layer an int specifying the desktop layer
- * @return an array of <code>JInternalFrame</code> objects
+ * @return an array of {@code JInternalFrame} objects
* @see JLayeredPane
*/
public JInternalFrame[] getAllFramesInLayer(int layer) {
Collection<JInternalFrame> allFrames = getAllFrames(this);
Iterator<JInternalFrame> iterator = allFrames.iterator();
@@ -441,16 +441,16 @@
super.remove(comp);
updateFramesCache();
}
/**
- * Selects the next <code>JInternalFrame</code> in this desktop pane.
+ * Selects the next {@code JInternalFrame} in this desktop pane.
*
* @param forward a boolean indicating which direction to select in;
- * <code>true</code> for forward, <code>false</code> for
+ * {@code true} for forward, {@code false} for
* backward
- * @return the JInternalFrame that was selected or <code>null</code>
+ * @return the JInternalFrame that was selected or {@code null}
* if nothing was selected
* @since 1.6
*/
public JInternalFrame selectFrame(boolean forward) {
JInternalFrame selectedFrame = getSelectedFrame();
@@ -470,11 +470,11 @@
return frameToSelect;
}
/*
* Sets whether component order checking is enabled.
- * @param enable a boolean value, where <code>true</code> means
+ * @param enable a boolean value, where {@code true} means
* a change in component order will cause a change in the keyboard
* navigation order.
* @since 1.6
*/
void setComponentOrderCheckingEnabled(boolean enable) {
@@ -568,17 +568,17 @@
super.setUIProperty(propertyName, value);
}
}
/**
- * Returns a string representation of this <code>JDesktopPane</code>.
+ * Returns a string representation of this {@code JDesktopPane}.
* This method is intended to be used only for debugging purposes, and the
* content and format of the returned string may vary between
* implementations. The returned string may be empty but may not
- * be <code>null</code>.
+ * be {@code null}.
*
- * @return a string representation of this <code>JDesktopPane</code>
+ * @return a string representation of this {@code JDesktopPane}
*/
protected String paramString() {
String desktopManagerString = (desktopManager != null ?
desktopManager.toString() : "");
@@ -589,39 +589,39 @@
/////////////////
// Accessibility support
////////////////
/**
- * Gets the <code>AccessibleContext</code> associated with this
- * <code>JDesktopPane</code>. For desktop panes, the
- * <code>AccessibleContext</code> takes the form of an
- * <code>AccessibleJDesktopPane</code>.
- * A new <code>AccessibleJDesktopPane</code> instance is created if necessary.
+ * Gets the {@code AccessibleContext} associated with this
+ * {@code JDesktopPane}. For desktop panes, the
+ * {@code AccessibleContext} takes the form of an
+ * {@code AccessibleJDesktopPane}.
+ * A new {@code AccessibleJDesktopPane} instance is created if necessary.
*
- * @return an <code>AccessibleJDesktopPane</code> that serves as the
- * <code>AccessibleContext</code> of this <code>JDesktopPane</code>
+ * @return an {@code AccessibleJDesktopPane} that serves as the
+ * {@code AccessibleContext} of this {@code JDesktopPane}
*/
public AccessibleContext getAccessibleContext() {
if (accessibleContext == null) {
accessibleContext = new AccessibleJDesktopPane();
}
return accessibleContext;
}
/**
* This class implements accessibility support for the
- * <code>JDesktopPane</code> class. It provides an implementation of the
+ * {@code JDesktopPane} class. It provides an implementation of the
* Java Accessibility API appropriate to desktop pane user-interface
* elements.
* <p>
* <strong>Warning:</strong>
* Serialized objects of this class will not be compatible with
* future Swing releases. The current serialization support is
* appropriate for short term storage or RMI between applications running
* the same version of Swing. As of 1.4, support for long term storage
* of all JavaBeans™
- * has been added to the <code>java.beans</code> package.
+ * has been added to the {@code java.beans} package.
* Please see {@link java.beans.XMLEncoder}.
*/
@SuppressWarnings("serial") // Same-version serialization only
protected class AccessibleJDesktopPane extends AccessibleJComponent {
< prev index next >