I know that using ViewPager I can get current fragment index but how can I get previous fragment index?
Its not a problem when I go forward (i-1) but how about going backward? Maybe their is a way to detect which direction I swipe? or something else