I am trying to add "up" navigation to my app. The layout is that there is a FrameLayout to contain a fragment. I switch to new fragments by replacing this one but I can not add up navigation using the addToBackStack because I have replaced the fragment. If I use the add method then the fragments are both displayed. Is there a better way to deal with this? What should I do?
Add a comment...