shts / StoriesProgressView

show horizontal progress like instagram stories.
Apache License 2.0
885 stars 203 forks source link

Allow for customization of starting point of animation within an individual progress bar #44

Open troutslaps opened 3 years ago

troutslaps commented 3 years ago

Allows for passing a second argument to StoriesProgressView.startStories(...) which will allow the caller to specify at which duration to start the animation within the current progress bar from.

Example:


storiesProgressView = (StoriesProgressView) findViewById(R.id.stories);
storiesProgressView.setStoriesCount(6);
storiesProgressView.setStoryDuration(3000L);
// ...
// This will start the animation on half of the third progress bar
storiesProgressView.startStories(2, 1500L);```