jdk/src/share/classes/javax/swing/JDesktopPane.java
changeset 20169 d7fa6d7586c9
parent 17149 adce5338e9b5
child 20455 f6f9a0c2796b
equal deleted inserted replaced
20168:137788883a22 20169:d7fa6d7586c9
    48  * You create <code>JInternalFrame</code> objects and add them to the
    48  * You create <code>JInternalFrame</code> objects and add them to the
    49  * <code>JDesktopPane</code>. <code>JDesktopPane</code> extends
    49  * <code>JDesktopPane</code>. <code>JDesktopPane</code> extends
    50  * <code>JLayeredPane</code> to manage the potentially overlapping internal
    50  * <code>JLayeredPane</code> to manage the potentially overlapping internal
    51  * frames. It also maintains a reference to an instance of
    51  * frames. It also maintains a reference to an instance of
    52  * <code>DesktopManager</code> that is set by the UI
    52  * <code>DesktopManager</code> that is set by the UI
    53  * class for the current look and feel (L&F).  Note that <code>JDesktopPane</code>
    53  * class for the current look and feel (L&amp;F).  Note that <code>JDesktopPane</code>
    54  * does not support borders.
    54  * does not support borders.
    55  * <p>
    55  * <p>
    56  * This class is normally used as the parent of <code>JInternalFrames</code>
    56  * This class is normally used as the parent of <code>JInternalFrames</code>
    57  * to provide a pluggable <code>DesktopManager</code> object to the
    57  * to provide a pluggable <code>DesktopManager</code> object to the
    58  * <code>JInternalFrames</code>. The <code>installUI</code> of the
    58  * <code>JInternalFrames</code>. The <code>installUI</code> of the
    59  * L&F specific implementation is responsible for setting the
    59  * L&amp;F specific implementation is responsible for setting the
    60  * <code>desktopManager</code> variable appropriately.
    60  * <code>desktopManager</code> variable appropriately.
    61  * When the parent of a <code>JInternalFrame</code> is a <code>JDesktopPane</code>,
    61  * When the parent of a <code>JInternalFrame</code> is a <code>JDesktopPane</code>,
    62  * it should delegate most of its behavior to the <code>desktopManager</code>
    62  * it should delegate most of its behavior to the <code>desktopManager</code>
    63  * (closing, resizing, etc).
    63  * (closing, resizing, etc).
    64  * <p>
    64  * <p>
   144         });
   144         });
   145         updateUI();
   145         updateUI();
   146     }
   146     }
   147 
   147 
   148     /**
   148     /**
   149      * Returns the L&F object that renders this component.
   149      * Returns the L&amp;F object that renders this component.
   150      *
   150      *
   151      * @return the <code>DesktopPaneUI</code> object that
   151      * @return the <code>DesktopPaneUI</code> object that
   152      *   renders this component
   152      *   renders this component
   153      */
   153      */
   154     public DesktopPaneUI getUI() {
   154     public DesktopPaneUI getUI() {
   155         return (DesktopPaneUI)ui;
   155         return (DesktopPaneUI)ui;
   156     }
   156     }
   157 
   157 
   158     /**
   158     /**
   159      * Sets the L&F object that renders this component.
   159      * Sets the L&amp;F object that renders this component.
   160      *
   160      *
   161      * @param ui  the DesktopPaneUI L&F object
   161      * @param ui  the DesktopPaneUI L&amp;F object
   162      * @see UIDefaults#getUI
   162      * @see UIDefaults#getUI
   163      * @beaninfo
   163      * @beaninfo
   164      *        bound: true
   164      *        bound: true
   165      *       hidden: true
   165      *       hidden: true
   166      *    attribute: visualUpdate true
   166      *    attribute: visualUpdate true
   230         desktopManager = d;
   230         desktopManager = d;
   231         firePropertyChange("desktopManager", oldValue, desktopManager);
   231         firePropertyChange("desktopManager", oldValue, desktopManager);
   232     }
   232     }
   233 
   233 
   234     /**
   234     /**
   235      * Notification from the <code>UIManager</code> that the L&F has changed.
   235      * Notification from the <code>UIManager</code> that the L&amp;F has changed.
   236      * Replaces the current UI object with the latest version from the
   236      * Replaces the current UI object with the latest version from the
   237      * <code>UIManager</code>.
   237      * <code>UIManager</code>.
   238      *
   238      *
   239      * @see JComponent#updateUI
   239      * @see JComponent#updateUI
   240      */
   240      */
   242         setUI((DesktopPaneUI)UIManager.getUI(this));
   242         setUI((DesktopPaneUI)UIManager.getUI(this));
   243     }
   243     }
   244 
   244 
   245 
   245 
   246     /**
   246     /**
   247      * Returns the name of the L&F class that renders this component.
   247      * Returns the name of the L&amp;F class that renders this component.
   248      *
   248      *
   249      * @return the string "DesktopPaneUI"
   249      * @return the string "DesktopPaneUI"
   250      * @see JComponent#getUIClassID
   250      * @see JComponent#getUIClassID
   251      * @see UIDefaults#getUI
   251      * @see UIDefaults#getUI
   252      */
   252      */