Fix contact list not being sorted correctly when mixing case in contacts names
This commit is contained in:
parent
f635a1ba8c
commit
7ed9f49f9a
1 changed files with 2 additions and 2 deletions
|
@ -87,8 +87,8 @@ public class LinphoneContact implements Serializable, Comparable<LinphoneContact
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int compareTo(LinphoneContact contact) {
|
public int compareTo(LinphoneContact contact) {
|
||||||
String fullName = getFullName() != null ? getFullName() : "";
|
String fullName = getFullName() != null ? getFullName().toUpperCase(Locale.getDefault()) : "";
|
||||||
String contactFullName = contact.getFullName() != null ? contact.getFullName() : "";
|
String contactFullName = contact.getFullName() != null ? contact.getFullName().toUpperCase(Locale.getDefault()) : "";
|
||||||
/*String firstLetter = fullName == null || fullName.isEmpty() ? "" : fullName.substring(0, 1).toUpperCase(Locale.getDefault());
|
/*String firstLetter = fullName == null || fullName.isEmpty() ? "" : fullName.substring(0, 1).toUpperCase(Locale.getDefault());
|
||||||
String contactfirstLetter = contactFullName == null || contactFullName.isEmpty() ? "" : contactFullName.substring(0, 1).toUpperCase(Locale.getDefault());*/
|
String contactfirstLetter = contactFullName == null || contactFullName.isEmpty() ? "" : contactFullName.substring(0, 1).toUpperCase(Locale.getDefault());*/
|
||||||
return fullName.compareTo(contactFullName);
|
return fullName.compareTo(contactFullName);
|
||||||
|
|
Loading…
Reference in a new issue