fun getCurrentFragment() = fa.supportFragmentManager.getBackStackEntryAt(fa.supportFragmentManager.backStackEntryCount - 1)
where fa
is the fragment activity passed to your adapter
See: https://developer.android.com/develop/ui/views/animations/screen-slide-2