Replace with lambda

This commit is contained in:
Martin Fietz 2018-01-09 20:20:32 +01:00
parent 7e0a958f8a
commit df131cdd0d
1 changed files with 1 additions and 6 deletions

View File

@ -771,12 +771,7 @@ public class PreferenceController implements SharedPreferences.OnSharedPreferenc
Log.e(TAG, "Couldn't get list of configure Wi-Fi networks"); Log.e(TAG, "Couldn't get list of configure Wi-Fi networks");
return; return;
} }
Collections.sort(networks, new Comparator<WifiConfiguration>() { Collections.sort(networks, (x, y) -> x.SSID.compareTo(y.SSID));
@Override
public int compare(WifiConfiguration x, WifiConfiguration y) {
return x.SSID.compareTo(y.SSID);
}
});
selectedNetworks = new CheckBoxPreference[networks.size()]; selectedNetworks = new CheckBoxPreference[networks.size()];
List<String> prefValues = Arrays.asList(UserPreferences List<String> prefValues = Arrays.asList(UserPreferences
.getAutodownloadSelectedNetworks()); .getAutodownloadSelectedNetworks());