A custom and easy Fragment Stack Manager.
Don't worry about Fragment Stack anymore, focus on what you like and matters, create a better product. The Fragment Stack Manager will do all the hard work without change any of the main behaviors from Android.
Imagine the Activity just like a holder for fragments, you set the title, options menu and still can handle the ActivityResult, all inside the Fragment. And you can push/pop a Fragment whenever you have a Context (like inside an Adapter).
You can see a Sample Project here and learn more on the Wiki.
You just need to add the Maven Jitpack repository on Project Gradle:
allprojects {
repositories {
maven { url 'https://jitpack.io' }
}
}
and the library dependence on Module Gradle:
dependencies {
implementation 'com.github.douglasspgyn:FragmentStackManager:0.1.0'
}