public int compareTo(Object o) {
			TreeElement other = (TreeElement) o;
			if (leaf != other.leaf)
				// files come after directories
				return leaf ? 1 : -1;
			return fullName.compareTo(other.fullName);
		}