You can register the callback using the TabHost.onSetTabChangedListener () method and run the animation from there. However, you should also remember that TabHost is deprecated on Android, and you are trying to port the very “iOS-ish” behavior to Android, which may not be very natural for your users.
source
share