-
Notifications
You must be signed in to change notification settings - Fork 193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Jump to any item using setCurrentItem(3,true); is not working correctly #8
Comments
Please see pull request #15 for this fix. |
I have this fix, but still get an infinite for(); loop entry on about half of my calls to setCurrentItem(); |
Infinite for loop on some of your calls to setCurrentItem()? The fix essentially forwards the params of overloaded method @Override
public void setCurrentItem(int item) {
// offset the current item to ensure there is space to scroll
setCurrentItem(item, false);
}
@Override
public void setCurrentItem(int item, boolean smoothScroll) {
item = getOffsetAmount() + (item % getAdapter().getCount());
super.setCurrentItem(item, smoothScroll);
} |
I have 4 fragments. There are links from fragment0 to the 3 other fragments, and then a "BACK" link to fragment0 from the other fragments. It is a bit hit and miss as to whether you will get across or back to the main fragment or not. Half of the time it works and the other half of the time you hit the infinite loop and after 20 seconds you get the system isn't responding wait/ok/report dialogue. It was reported on stackoverflow that it failed if the transition was from a lower to a higher virtual position number, but I'm not sure it was thas simple. |
Do you see the same issue if you use |
The text was updated successfully, but these errors were encountered: