Ignore:
Timestamp:
2016-07-24T00:19:35+02:00 (8 years ago)
Author:
Don-vip
Message:

see #11390 - Java 8: use List.sort(Comparator) instead of Collections.sort(list, Comparator)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/preferences/SourceEditor.java

    r10611 r10619  
    12231223
    12241224        protected void sort() {
    1225             Collections.sort(data,
    1226                     (o1, o2) -> {
    1227                         if (o1.isEmpty() && o2.isEmpty())
    1228                             return 0;
    1229                         if (o1.isEmpty()) return 1;
    1230                         if (o2.isEmpty()) return -1;
    1231                         return o1.compareTo(o2);
    1232                     });
     1225            data.sort((o1, o2) -> {
     1226                    if (o1.isEmpty() && o2.isEmpty())
     1227                        return 0;
     1228                    if (o1.isEmpty()) return 1;
     1229                    if (o2.isEmpty()) return -1;
     1230                    return o1.compareTo(o2);
     1231                });
    12331232        }
    12341233
Note: See TracChangeset for help on using the changeset viewer.