Problem: Fragment onResume() in ViewPager is fired before the fragment becomes actually visible.
For example, I have 2 fragments with
Override Fragment.onHiddenChanged() for that.
public void onHiddenChanged(boolean hidden)Called when the hidden state (as returned by isHidden()) of the fragment has changed. Fragments start out not hidden; this will be called whenever the fragment changes state from that.
Parameters
hidden-boolean: True if the fragment is now hidden, false if it is not visible.