mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-22 22:28:13 +00:00
Fixed unecessary reloading of nav graph when app is going from background to foreground
This commit is contained in:
parent
1d7ca67053
commit
b80f520162
1 changed files with 2 additions and 8 deletions
|
|
@ -153,9 +153,7 @@ class MainActivity : AppCompatActivity() {
|
|||
showGreenToast(message, icon)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onStart() {
|
||||
coreContext.postOnCoreThread {
|
||||
val startDestination = when (corePreferences.defaultFragment) {
|
||||
CONTACTS_FRAGMENT_ID -> {
|
||||
|
|
@ -187,15 +185,11 @@ class MainActivity : AppCompatActivity() {
|
|||
if (intent != null) {
|
||||
handleIntent(intent, startDestination, false)
|
||||
} else {
|
||||
/*val navGraph = findNavController().navInflater.inflate(R.navigation.main_nav_graph)
|
||||
navGraph.setStartDestination(startDestination)
|
||||
findNavController().setGraph(navGraph, null)*/
|
||||
Log.e("$TAG Started without intent !")
|
||||
// This should never happen!
|
||||
Log.e("$TAG onPostCreate called without intent !")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
super.onStart()
|
||||
}
|
||||
|
||||
override fun onPause() {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue