Updated on 2026-08-14
This commit is contained in:
parent
6955247ada
commit
652849641b
1 changed files with 6 additions and 1 deletions
|
|
@ -25,6 +25,7 @@ import com.tangem.tap.features.tokens.ui.AddTokensFragment
|
|||
import com.tangem.tap.features.wallet.ui.WalletDetailsFragment
|
||||
import com.tangem.tap.features.wallet.ui.WalletFragment
|
||||
import com.tangem.wallet.R
|
||||
import timber.log.Timber
|
||||
|
||||
private class Navigation
|
||||
|
||||
|
|
@ -52,7 +53,11 @@ fun FragmentActivity.openFragment(
|
|||
|
||||
fun FragmentActivity.popBackTo(screen: AppScreen?, inclusive: Boolean = false) {
|
||||
val inclusiveFlag = if (inclusive) FragmentManager.POP_BACK_STACK_INCLUSIVE else 0
|
||||
this.supportFragmentManager.popBackStack(screen?.name, inclusiveFlag)
|
||||
try {
|
||||
this.supportFragmentManager.popBackStack(screen?.name, inclusiveFlag)
|
||||
} catch (e: IllegalStateException) {
|
||||
Timber.e(e)
|
||||
}
|
||||
}
|
||||
|
||||
fun FragmentActivity.getPreviousScreen(): AppScreen? {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue