mirror of
https://github.com/SimpleMobileTools/Simple-Contacts.git
synced 2025-01-18 18:19:54 +01:00
normalize names at the dialpad letter search
This commit is contained in:
parent
2974d828a8
commit
d4d7592666
@ -173,8 +173,8 @@ class DialpadActivity : SimpleActivity() {
|
||||
val showLetters = config.showDialpadLetters
|
||||
(dialpad_list.adapter as? ContactsAdapter)?.finishActMode()
|
||||
val filtered = contacts.filter {
|
||||
val convertedName = PhoneNumberUtils.convertKeypadLettersToDigits(it.getNameToDisplay())
|
||||
val company = PhoneNumberUtils.convertKeypadLettersToDigits(it.getFullCompany())
|
||||
val convertedName = PhoneNumberUtils.convertKeypadLettersToDigits(it.getNameToDisplay().normalizeString())
|
||||
val company = PhoneNumberUtils.convertKeypadLettersToDigits(it.getFullCompany().normalizeString())
|
||||
it.doesContainPhoneNumber(text, showLetters) || (showLetters && (convertedName.contains(text, true) || company.contains(text, true)))
|
||||
}.sortedWith(compareBy {
|
||||
if (showLetters) {
|
||||
|
Loading…
Reference in New Issue
Block a user