updating commons with PhoneNumber containing multiple fields
This commit is contained in:
parent
07e906e19c
commit
591f473a1f
10 changed files with 39 additions and 31 deletions
|
|
@ -42,7 +42,7 @@ class AutoCompleteTextViewAdapter(val activity: SimpleActivity, val contacts: Ar
|
|||
|
||||
if (contact != null) {
|
||||
findViewById<TextView>(R.id.item_contact_name).text = contact.name
|
||||
findViewById<TextView>(R.id.item_contact_number).text = contact.phoneNumbers.first()
|
||||
findViewById<TextView>(R.id.item_contact_number).text = contact.phoneNumbers.first().normalizedNumber
|
||||
SimpleContactsHelper(context).loadContactImage(contact.photoUri, findViewById(R.id.item_contact_image), contact.name)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ class ContactsAdapter(
|
|||
}
|
||||
|
||||
findViewById<TextView>(R.id.item_contact_number).apply {
|
||||
text = contact.phoneNumbers.first()
|
||||
text = contact.phoneNumbers.first().normalizedNumber
|
||||
setTextColor(textColor)
|
||||
setTextSize(TypedValue.COMPLEX_UNIT_PX, fontSize)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -237,7 +237,7 @@ class ThreadAdapter(
|
|||
thread_message_sender_photo.beVisible()
|
||||
thread_message_sender_photo.setOnClickListener {
|
||||
val contact = message.participants.first()
|
||||
context.getContactFromAddress(contact.phoneNumbers.first()) {
|
||||
context.getContactFromAddress(contact.phoneNumbers.first().normalizedNumber) {
|
||||
if (it != null) {
|
||||
(activity as ThreadActivity).startContactDetailsIntent(it)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue