Hi!

This patch fixes a number of bugs in javax.swing packages (and also makes a 
number of package-visible variables in UIManager private).

ChangeLog entries:
        * javax/swing/JFileChooser.java (setCurrentDirectory): Handle null
        "dir" case first; call isTraversable for "dir" (if not traversable
        then go to the parent until a traversable one is found); call
        firePropertyChange() only if new "dir" is not equal to "currentDir"
        value (the same as in RI).
        * javax/swing/UIManager.java (installed, auxLookAndFeels,
        currentLookAndFeel, currentUIDefaults, lookAndFeelDefaults): Make
        the static variable private.
        * javax/swing/UIManager.java (<clinit>): Use
        getCrossPlatformLookAndFeelClassName() instead of a direct
        MetalLookAndFeel constructor invocation (in case of unset
        "swing.defaultlaf" property).
        * javax/swing/UIManager.java (setInstalledLookAndFeels): Check for
        null "infos" parameter.
        * javax/swing/filechooser/FileSystemView.java (getFiles): Don't call
        listFiles() twice; return an empty array in case of a non-existent
        directory (as in RI).
        * javax/swing/plaf/basic/BasicInternalFrameUI.java (componentResized):
        Ignore if "frame" is null.
        * javax/swing/plaf/basic/BasicToolBarUI.java (dragTo): Don't call
        setBounds() if "p" offset is null.
        * javax/swing/plaf/basic/BasicToolBarUI.java (floatAt): Likewise for
        setFloatingLocation().
        * javax/swing/plaf/basic/BasicToolBarUI.java (mousePressed): Don't
        call setOffset() if cachedBounds is null.
        * javax/swing/plaf/basic/BasicTreeUI.java (getNodeDimensions): Defend
        against null currentCellRenderer.
        * javax/swing/text/FieldView.java (checkContainer): Use "c" local
        variable (instead of getContainer()) in ChangeListener.stateChanged()
        (at least to guard against NPE).
        * javax/swing/tree/FixedHeightLayoutCache.java (getBounds): Don't
        set r.bounds in case of null returned by getNodeDimensions().
        * javax/swing/tree/VariableHeightLayoutCache.java (countRows): If
        getNodeDimensions() returns null then use RECT_CACHE and setBounds().

Attachment: classpath-ivmai-06.diff
Description: Binary data

Reply via email to