src/share/classes/javax/swing/tree/AbstractLayoutCache.java
Print this page
*** 226,239 ****
else {
firstPath = getPathClosestTo(bounds.x, bounds.y);
endY = bounds.height + bounds.y;
}
! Enumeration paths = getVisiblePathsFrom(firstPath);
if(paths != null && paths.hasMoreElements()) {
! Rectangle pBounds = getBounds((TreePath)paths.nextElement(),
null);
int width;
if(pBounds != null) {
width = pBounds.x + pBounds.width;
--- 226,239 ----
else {
firstPath = getPathClosestTo(bounds.x, bounds.y);
endY = bounds.height + bounds.y;
}
! Enumeration<TreePath> paths = getVisiblePathsFrom(firstPath);
if(paths != null && paths.hasMoreElements()) {
! Rectangle pBounds = getBounds(paths.nextElement(),
null);
int width;
if(pBounds != null) {
width = pBounds.x + pBounds.width;
*** 242,252 ****
}
}
else
width = 0;
while (pBounds != null && paths.hasMoreElements()) {
! pBounds = getBounds((TreePath)paths.nextElement(),
pBounds);
if (pBounds != null && pBounds.y < endY) {
width = Math.max(width, pBounds.x + pBounds.width);
}
else {
--- 242,252 ----
}
}
else
width = 0;
while (pBounds != null && paths.hasMoreElements()) {
! pBounds = getBounds(paths.nextElement(),
pBounds);
if (pBounds != null && pBounds.y < endY) {
width = Math.max(width, pBounds.x + pBounds.width);
}
else {