summaryrefslogtreecommitdiff
path: root/javax/swing/tree/VariableHeightLayoutCache.java
diff options
context:
space:
mode:
authorAndrew John Hughes <gnu_andrew@member.fsf.org>2006-10-05 02:44:18 +0000
committerAndrew John Hughes <gnu_andrew@member.fsf.org>2006-10-05 02:44:18 +0000
commit2799793789d5b66c90efbd1a3eb56e0c1ec57f88 (patch)
tree9157197f502b6830af9cafe029fd3d47628a7ed6 /javax/swing/tree/VariableHeightLayoutCache.java
parent7516107c5abe26f7a4378017344eb9e449ebc28e (diff)
downloadclasspath-2799793789d5b66c90efbd1a3eb56e0c1ec57f88.tar.gz
2006-10-05 Andrew John Hughes <gnu_andrew@member.fsf.org>
* Merge of HEAD-->generics for 2006/09/03-2006/10/04.
Diffstat (limited to 'javax/swing/tree/VariableHeightLayoutCache.java')
-rw-r--r--javax/swing/tree/VariableHeightLayoutCache.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/javax/swing/tree/VariableHeightLayoutCache.java b/javax/swing/tree/VariableHeightLayoutCache.java
index 03251eb1f..b256f1fe9 100644
--- a/javax/swing/tree/VariableHeightLayoutCache.java
+++ b/javax/swing/tree/VariableHeightLayoutCache.java
@@ -339,6 +339,12 @@ public class VariableHeightLayoutCache
return null;
if (dirty)
update();
+
+ // The RI allows null arguments for rect, in which case a new Rectangle
+ // is created.
+ if (rect == null)
+ rect = new Rectangle();
+
Object last = path.getLastPathComponent();
NodeRecord r = (NodeRecord) nodes.get(last);
if (r == null)