mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-17 11:28:06 +00:00
Prevent going back to operation in progress dialog after hanging up started group call, also go back to calls history
This commit is contained in:
parent
4afa2ebc93
commit
990549eb24
2 changed files with 13 additions and 3 deletions
|
|
@ -120,7 +120,11 @@ class StartCallFragment : GenericAddressPickerFragment() {
|
|||
|
||||
viewModel.leaveFragmentEvent.observe(viewLifecycleOwner) {
|
||||
it.consume {
|
||||
goBack()
|
||||
// Post on main thread to allow for main activity to be resumed
|
||||
coreContext.postOnMainThread {
|
||||
Log.i("$TAG Going back")
|
||||
goBack()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -84,8 +84,14 @@ class StartCallViewModel
|
|||
@WorkerThread
|
||||
override fun onStateChanged(conference: Conference, newState: Conference.State?) {
|
||||
Log.i("$TAG Conference state changed [$newState]")
|
||||
if (newState == Conference.State.Created || newState == Conference.State.CreationFailed) {
|
||||
operationInProgress.postValue(false)
|
||||
when (newState) {
|
||||
Conference.State.Created, Conference.State.CreationFailed, Conference.State.TerminationPending -> {
|
||||
operationInProgress.postValue(false)
|
||||
}
|
||||
Conference.State.Terminated -> {
|
||||
leaveFragmentEvent.postValue(Event(true))
|
||||
}
|
||||
else -> {}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue