mirror of
https://github.com/SimpleMobileTools/Simple-Contacts.git
synced 2025-06-05 21:59:27 +02:00
show a toast message when trying to call someone without phone number
This commit is contained in:
@ -163,7 +163,12 @@ class MainActivity : SimpleActivity(), RefreshRecyclerViewListener {
|
|||||||
if (currAdapter == null) {
|
if (currAdapter == null) {
|
||||||
ContactsAdapter(this, contacts, this, contacts_list) {
|
ContactsAdapter(this, contacts, this, contacts_list) {
|
||||||
if (config.callContact) {
|
if (config.callContact) {
|
||||||
tryStartCall(it as Contact)
|
val contact = it as Contact
|
||||||
|
if (contact.phoneNumbers.isNotEmpty()) {
|
||||||
|
tryStartCall(it)
|
||||||
|
} else {
|
||||||
|
toast(R.string.no_phone_number_found)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
openContact(it as Contact)
|
openContact(it as Contact)
|
||||||
}
|
}
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<string name="work_fax">Arbeit Fax</string>
|
<string name="work_fax">Arbeit Fax</string>
|
||||||
<string name="home_fax">Privat Fax</string>
|
<string name="home_fax">Privat Fax</string>
|
||||||
<string name="pager">Pager</string>
|
<string name="pager">Pager</string>
|
||||||
|
<string name="no_phone_number_found">No phone number has been found</string>
|
||||||
|
|
||||||
<!-- Events -->
|
<!-- Events -->
|
||||||
<string name="birthday">Geburtstag</string>
|
<string name="birthday">Geburtstag</string>
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<string name="work_fax">Work Fax</string>
|
<string name="work_fax">Work Fax</string>
|
||||||
<string name="home_fax">Home Fax</string>
|
<string name="home_fax">Home Fax</string>
|
||||||
<string name="pager">Pager</string>
|
<string name="pager">Pager</string>
|
||||||
|
<string name="no_phone_number_found">No phone number has been found</string>
|
||||||
|
|
||||||
<!-- Events -->
|
<!-- Events -->
|
||||||
<string name="birthday">Birthday</string>
|
<string name="birthday">Birthday</string>
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<string name="work_fax">Work Fax</string>
|
<string name="work_fax">Work Fax</string>
|
||||||
<string name="home_fax">Home Fax</string>
|
<string name="home_fax">Home Fax</string>
|
||||||
<string name="pager">Pager</string>
|
<string name="pager">Pager</string>
|
||||||
|
<string name="no_phone_number_found">No phone number has been found</string>
|
||||||
|
|
||||||
<!-- Events -->
|
<!-- Events -->
|
||||||
<string name="birthday">Birthday</string>
|
<string name="birthday">Birthday</string>
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<string name="work_fax">Pracovný fax</string>
|
<string name="work_fax">Pracovný fax</string>
|
||||||
<string name="home_fax">Domáci fax</string>
|
<string name="home_fax">Domáci fax</string>
|
||||||
<string name="pager">Pager</string>
|
<string name="pager">Pager</string>
|
||||||
|
<string name="no_phone_number_found">Nenašlo sa žiadne telefónne číslo</string>
|
||||||
|
|
||||||
<!-- Events -->
|
<!-- Events -->
|
||||||
<string name="birthday">Narodeniny</string>
|
<string name="birthday">Narodeniny</string>
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<string name="work_fax">Work Fax</string>
|
<string name="work_fax">Work Fax</string>
|
||||||
<string name="home_fax">Home Fax</string>
|
<string name="home_fax">Home Fax</string>
|
||||||
<string name="pager">Pager</string>
|
<string name="pager">Pager</string>
|
||||||
|
<string name="no_phone_number_found">No phone number has been found</string>
|
||||||
|
|
||||||
<!-- Events -->
|
<!-- Events -->
|
||||||
<string name="birthday">Birthday</string>
|
<string name="birthday">Birthday</string>
|
||||||
|
Reference in New Issue
Block a user