make sure the Call and SMS buttons are shown when necessary

This commit is contained in:
tibbi 2020-05-15 12:08:52 +02:00
parent e646d88a2e
commit c23800f28b
2 changed files with 7 additions and 1 deletions

View File

@ -57,7 +57,7 @@ android {
}
dependencies {
implementation 'com.simplemobiletools:commons:5.28.1'
implementation 'com.simplemobiletools:commons:5.28.2'
implementation 'joda-time:joda-time:2.10.1'
implementation 'com.googlecode.ez-vcard:ez-vcard:0.10.5'
implementation 'com.github.tibbi:IndicatorFastScroll:08f512858a'

View File

@ -338,6 +338,12 @@ class ViewContactActivity : ContactActivity() {
contact_numbers_image.beGone()
contact_numbers_holder.beGone()
}
// make sure the Call and SMS buttons are visible if any phone number is shown
if (phoneNumbers.isNotEmpty()) {
contact_send_sms.beVisible()
contact_start_call.beVisible()
}
}
// a contact cannot have different emails per contact source. Such contacts are handled as separate ones, not duplicates of each other