6956842: BasicTreeUI.getPreferredSize(JComp c) is delegated to getPreferredSize(c, true) not (c, false)
authoralexp
Tue, 15 Feb 2011 16:40:25 +0300
changeset 8374 d262ac869cda
parent 8373 7e8b793dbf91
child 8375 7b37813b7461
6956842: BasicTreeUI.getPreferredSize(JComp c) is delegated to getPreferredSize(c, true) not (c, false) Reviewed-by: rupashka
jdk/src/share/classes/javax/swing/plaf/basic/BasicTreeUI.java
--- a/jdk/src/share/classes/javax/swing/plaf/basic/BasicTreeUI.java	Fri Feb 11 12:14:38 2011 -0800
+++ b/jdk/src/share/classes/javax/swing/plaf/basic/BasicTreeUI.java	Tue Feb 15 16:40:25 2011 +0300
@@ -1965,18 +1965,18 @@
     }
 
     /** Returns the preferred size to properly display the tree,
-      * this is a cover method for getPreferredSize(c, false).
+      * this is a cover method for getPreferredSize(c, true).
       */
     public Dimension getPreferredSize(JComponent c) {
         return getPreferredSize(c, true);
     }
 
     /** Returns the preferred size to represent the tree in
-      * <I>c</I>.  If <I>checkConsistancy</I> is true
-      * <b>checkConsistancy</b> is messaged first.
+      * <I>c</I>.  If <I>checkConsistency</I> is true
+      * <b>checkConsistency</b> is messaged first.
       */
     public Dimension getPreferredSize(JComponent c,
-                                      boolean checkConsistancy) {
+                                      boolean checkConsistency) {
         Dimension       pSize = this.getPreferredMinSize();
 
         if(!validCachedPreferredSize)