How to make the maximum stack size in 5 fragments. Adding 6 fragments, 1 fragment should be deleted, but calmly, without displaying the screen.
[Fragment1] β [FRAGMENT2] β [Fragment3] β [Fragment4] β [Fragment5]
6 fragments added
<y> [Fragment1] [FRAGMENT2] β [Fragment3] β [Fragment4] β [Fragment5] β [Fragment6]
when the user returns, he will be on 5 screens.
The main problem is how to remove FragmentManager.BackStackEntry from the stop fragment manager in silent mode without clicking on the screen.
Is it possible?
android fragments
AndreyNik
source share