Open nickimola opened 7 years ago
Thanks for the report. My guess is that the browser stops requestAnimationFrame
when it gets minimized and then doesn't resume it when restoring focus.
Do you know if there's a way to manually force it to restart when the app goes back to focus?
You may be able to do it by setting the value again on window.addEventListener('focus')
.
That is because the app in this case is not the main thread when you put it away you can avoid it using a web worker on Javascript and sending updates to the user interface. I know you're talking about native apps but this happens to me once using cordova to implement a user interface for a WiFi timer on a pfSense project and solved using a web worker since the scope of it is independent and that thread don't loose CPU cycles. That is also the way to go for push notifications but that is another topic.
On Mon, Feb 27, 2017, 6:58 AM Kristiyan Kostadinov notifications@github.com wrote:
You may be able to do it by setting the value again on window.addEventListener('focus').
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/crisbeto/angular-svg-round-progressbar/issues/111#issuecomment-282701257, or mute the thread https://github.com/notifications/unsubscribe-auth/AMqTzxeMe4GFZtqF2Tr5znJLkEbD3ZMcks5rgrpHgaJpZM4MM_Tk .
--
Sent from my Nexus 6P.
Hi,
I've just noticed that on Android and iOS, when I minify the app, the timer is not refreshing properly.
How to reproduce:
Am I the only one facing this issue? Is it possible to fix?
I have also noticed that on android, if I set duration to 0, it updates properly, but still not on iOS.
Thanks