mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-17 11:28:06 +00:00
Fixed crash when touching multiple calls top bar if not on active call fragment + fixed top bar alert & status bar color after terminating more than one call
This commit is contained in:
parent
bf089193d4
commit
8fb87b18e8
3 changed files with 9 additions and 3 deletions
|
|
@ -252,8 +252,11 @@ class CallActivity : GenericActivity() {
|
|||
callsViewModel.goToCallsListEvent.observe(this) {
|
||||
it.consume {
|
||||
val navController = findNavController(R.id.call_nav_container)
|
||||
val action = ActiveCallFragmentDirections.actionActiveCallFragmentToCallsListFragment()
|
||||
navController.navigate(action)
|
||||
if (navController.currentDestination?.id == R.id.activeCallFragment) {
|
||||
val action =
|
||||
ActiveCallFragmentDirections.actionActiveCallFragmentToCallsListFragment()
|
||||
navController.navigate(action)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ class ActiveCallFragment : GenericCallFragment() {
|
|||
}
|
||||
|
||||
override fun onCreateAnimation(transit: Int, enter: Boolean, nextAnim: Int): Animation? {
|
||||
if (findNavController().currentDestination?.id == R.id.newCallFragment) {
|
||||
if (findNavController().currentDestination?.id == R.id.newCallFragment || findNavController().currentDestination?.id == R.id.callsListFragment) {
|
||||
// Holds fragment in place while new fragment slides over it
|
||||
return AnimationUtils.loadAnimation(activity, R.anim.hold)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -122,6 +122,9 @@ class MainViewModel @UiThread constructor() : ViewModel() {
|
|||
) {
|
||||
updateCallAlert()
|
||||
} else if (core.callsNb == 1) {
|
||||
if (LinphoneUtils.isCallEnding(call.state)) {
|
||||
removeAlert(MULTIPLE_CALLS)
|
||||
}
|
||||
callsStatus.postValue(LinphoneUtils.callStateToString(call.state))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue