You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pivot.apache.org by gb...@apache.org on 2009/06/26 20:29:10 UTC
svn commit: r788807 -
/incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java
Author: gbrown
Date: Fri Jun 26 18:29:09 2009
New Revision: 788807
URL: http://svn.apache.org/viewvc?rev=788807&view=rev
Log:
Check for empty path in TreeView#setBranchExpanded().
Modified:
incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java
Modified: incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java?rev=788807&r1=788806&r2=788807&view=diff
==============================================================================
--- incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java (original)
+++ incubator/pivot/trunk/wtk/src/org/apache/pivot/wtk/TreeView.java Fri Jun 26 18:29:09 2009
@@ -1561,6 +1561,10 @@
throw new IllegalArgumentException("path is null.");
}
+ if (path.getLength() == 0) {
+ throw new IllegalArgumentException("path is empty.");
+ }
+
int index = expandedPaths.indexOf(path);
if (expanded && index < 0) {