try parsing contact name from Insert intent, related to #125
This commit is contained in:
parent
24bb8a331b
commit
e999c3a275
|
@ -49,6 +49,7 @@ class EditContactActivity : ContactActivity() {
|
||||||
private val REMOVE_PHOTO = 3
|
private val REMOVE_PHOTO = 3
|
||||||
|
|
||||||
private val KEY_PHONE = "phone"
|
private val KEY_PHONE = "phone"
|
||||||
|
private val KEY_NAME = "name"
|
||||||
|
|
||||||
private var wasActivityInitialized = false
|
private var wasActivityInitialized = false
|
||||||
private var lastPhotoIntentUri: Uri? = null
|
private var lastPhotoIntentUri: Uri? = null
|
||||||
|
@ -150,6 +151,9 @@ class EditContactActivity : ContactActivity() {
|
||||||
val phoneNumber = intent.extras.get(KEY_PHONE).toString()
|
val phoneNumber = intent.extras.get(KEY_PHONE).toString()
|
||||||
contact!!.phoneNumbers.add(PhoneNumber(phoneNumber, DEFAULT_PHONE_NUMBER_TYPE))
|
contact!!.phoneNumbers.add(PhoneNumber(phoneNumber, DEFAULT_PHONE_NUMBER_TYPE))
|
||||||
setupPhoneNumbers()
|
setupPhoneNumbers()
|
||||||
|
|
||||||
|
val contactFullName = intent.extras.get(KEY_NAME).toString()
|
||||||
|
contact_first_name.setText(contactFullName)
|
||||||
}
|
}
|
||||||
|
|
||||||
setupTypePickers()
|
setupTypePickers()
|
||||||
|
|
Loading…
Reference in New Issue