Created
January 7, 2014 09:41
-
-
Save ikew0ng/8297033 to your computer and use it in GitHub Desktop.
Clear fragment backStack
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Remove all entries from the backStack of this fragmentManager. | |
* | |
* @param fragmentManager the fragmentManager to clear. | |
*/ | |
private void clearBackStack(FragmentManager fragmentManager) { | |
if (fragmentManager.getBackStackEntryCount() > 0) { | |
FragmentManager.BackStackEntry entry = fragmentManager.getBackStackEntryAt(0); | |
mFragmentManager.popBackStack(entry.getId(), FragmentManager.POP_BACK_STACK_INCLUSIVE); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Fixed an issue I was having.