Skip to content
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

FlipClock.countdown not updating #8

Closed
chwzr opened this issue Dec 29, 2018 · 1 comment
Closed

FlipClock.countdown not updating #8

chwzr opened this issue Dec 29, 2018 · 1 comment

Comments

@chwzr
Copy link

chwzr commented Dec 29, 2018

I am using FlipClock in my current Flutter project. I'm displaying a Countdown with

FlipClock.countdown(
         duration: remainingTime,
         digitColor: loopWhite,
         backgroundColor: loopDarkBlue,
         digitSize: 25.0,
);

This is working well, but when i change the state of remainingTime the FlipClock does not update to the new Duration. Can you point me in some direction?

Kind Regards

@chwzr
Copy link
Author

chwzr commented Dec 29, 2018

never mind. Added a prop endTime to your class, and recalculate the timeLeft inside the Stream, with endTime.difference(DateTime.now()) instead of the last timeLeft value ;)

@chwzr chwzr closed this as completed Dec 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant