You need to have your back and keep an eye on it.
Take a look at this: http://adblogcat.com/fragment-transition-animations-while-hiding-the-previous-fragment/
The code contains its own stack of fragments and hides them instead of deleting them, giving it the same effect as the replacement (with backstack), except that it does not recreate the fragment every time, so the state of the fragment remains unchanged.
However, this code has a memory leak, and I should update it last, where fragments are not saved. Hope this helps.
Juan Acevedo Jul 31. '13 at 23:14 2013-07-31 23:14
source share