X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=org.argeo.eclipse.ui%2Fsrc%2Forg%2Fargeo%2Feclipse%2Fui%2Fjcr%2Futils%2FJcrItemsComparator.java;h=015670ba58e419ab052edfa356c7cec894d98426;hb=5ec9d72c96b13bf18d702bf01dc2c03b0aee43a4;hp=2d36bf28a3f6c2ab1acdcb2563052228fded4d59;hpb=e61dd9dda88354091625cca85aa7c96d196688b3;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.eclipse.ui/src/org/argeo/eclipse/ui/jcr/utils/JcrItemsComparator.java b/org.argeo.eclipse.ui/src/org/argeo/eclipse/ui/jcr/utils/JcrItemsComparator.java index 2d36bf28a..015670ba5 100644 --- a/org.argeo.eclipse.ui/src/org/argeo/eclipse/ui/jcr/utils/JcrItemsComparator.java +++ b/org.argeo.eclipse.ui/src/org/argeo/eclipse/ui/jcr/utils/JcrItemsComparator.java @@ -20,16 +20,16 @@ import java.util.Comparator; import javax.jcr.Item; import javax.jcr.RepositoryException; -import org.argeo.ArgeoException; +import org.argeo.eclipse.ui.EclipseUiException; /** Compares two JCR items (node or properties) based on their names. */ public class JcrItemsComparator implements Comparator { public int compare(Item o1, Item o2) { try { // TODO: put folder before files - return o1.getName().compareTo(o2.getName()); + return o1.getName().toLowerCase().compareTo(o2.getName().toLowerCase()); } catch (RepositoryException e) { - throw new ArgeoException("Cannot compare " + o1 + " and " + o2, e); + throw new EclipseUiException("Cannot compare " + o1 + " and " + o2, e); } }