Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

minor CountDownView.java bug #3

Open
AlephNull0 opened this issue Feb 1, 2014 · 0 comments
Open

minor CountDownView.java bug #3

AlephNull0 opened this issue Feb 1, 2014 · 0 comments

Comments

@AlephNull0
Copy link

Not that it makes a noticeable difference, but I'm looking at the else in the updateView method within CountDownView.java and think the line

float factor = (frame - ANIMATION_DURATION_IN_MILLIS) / ANIMATION_DURATION_IN_MILLIS;

should be changed to

float factor = (frame - ANIMATION_DURATION_IN_MILLIS) / (SEC_TO_MILLIS - ANIMATION_DURATION_IN_MILLIS);

so the alpha value of the TextView is expected to approach one at the end of every interval. Instead, it approaches (1000 - 850)/850*0.05 + 0.95 = 0.9588.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant