mirror of
https://github.com/SimpleMobileTools/Simple-Contacts.git
synced 2025-06-05 21:59:27 +02:00
hide keyboard on a couple more places
This commit is contained in:
@ -357,6 +357,7 @@ class EditContactActivity : ContactActivity() {
|
|||||||
imageUri = getCachePhotoUri(newFile)
|
imageUri = getCachePhotoUri(newFile)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
hideKeyboard()
|
||||||
lastPhotoIntentUri = getCachePhotoUri()
|
lastPhotoIntentUri = getCachePhotoUri()
|
||||||
Intent("com.android.camera.action.CROP").apply {
|
Intent("com.android.camera.action.CROP").apply {
|
||||||
setDataAndType(imageUri, "image/*")
|
setDataAndType(imageUri, "image/*")
|
||||||
@ -599,6 +600,7 @@ class EditContactActivity : ContactActivity() {
|
|||||||
|
|
||||||
private fun setupRingtone() {
|
private fun setupRingtone() {
|
||||||
contact_ringtone.setOnClickListener {
|
contact_ringtone.setOnClickListener {
|
||||||
|
hideKeyboard()
|
||||||
val ringtonePickerIntent = getRingtonePickerIntent()
|
val ringtonePickerIntent = getRingtonePickerIntent()
|
||||||
try {
|
try {
|
||||||
startActivityForResult(ringtonePickerIntent, INTENT_SELECT_RINGTONE)
|
startActivityForResult(ringtonePickerIntent, INTENT_SELECT_RINGTONE)
|
||||||
@ -1441,6 +1443,7 @@ class EditContactActivity : ContactActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun startTakePhotoIntent() {
|
private fun startTakePhotoIntent() {
|
||||||
|
hideKeyboard()
|
||||||
val uri = getCachePhotoUri()
|
val uri = getCachePhotoUri()
|
||||||
lastPhotoIntentUri = uri
|
lastPhotoIntentUri = uri
|
||||||
Intent(MediaStore.ACTION_IMAGE_CAPTURE).apply {
|
Intent(MediaStore.ACTION_IMAGE_CAPTURE).apply {
|
||||||
@ -1457,6 +1460,7 @@ class EditContactActivity : ContactActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun startChoosePhotoIntent() {
|
private fun startChoosePhotoIntent() {
|
||||||
|
hideKeyboard()
|
||||||
val uri = getCachePhotoUri()
|
val uri = getCachePhotoUri()
|
||||||
lastPhotoIntentUri = uri
|
lastPhotoIntentUri = uri
|
||||||
Intent(Intent.ACTION_PICK).apply {
|
Intent(Intent.ACTION_PICK).apply {
|
||||||
|
@ -208,6 +208,7 @@ abstract class MyViewPagerFragment(context: Context, attributeSet: AttributeSet)
|
|||||||
val currAdapter = fragment_list.adapter
|
val currAdapter = fragment_list.adapter
|
||||||
if (currAdapter == null) {
|
if (currAdapter == null) {
|
||||||
GroupsAdapter(activity as SimpleActivity, storedGroups, activity as RefreshContactsListener, fragment_list) {
|
GroupsAdapter(activity as SimpleActivity, storedGroups, activity as RefreshContactsListener, fragment_list) {
|
||||||
|
activity?.hideKeyboard()
|
||||||
Intent(activity, GroupContactsActivity::class.java).apply {
|
Intent(activity, GroupContactsActivity::class.java).apply {
|
||||||
putExtra(GROUP, it as Group)
|
putExtra(GROUP, it as Group)
|
||||||
activity!!.startActivity(this)
|
activity!!.startActivity(this)
|
||||||
|
Reference in New Issue
Block a user