Open
Description
I used display 3 cards at the same time on RecyclerView, but I always encounter extra highlight "tail" indicator even if I already moved to next card.
After some debugging, I modify the progress variable in LinePagerIndicatorDecoration.java.
`
// on swipe the active item will be positioned from [-width, 0]
// interpolate offset for smooth animation
float progress = mInterpolator.getInterpolation(left * -1 / (float) width);
// extra "rounding"
if(progress < 0.02) {
progress = 0;
} else if (progress > 0.98) {
// rounding, avoid extra highlighted part
progress = 0;
activePosition++;
}
`
FYI.
Metadata
Assignees
Labels
No labels