I have a timer, it successfully countdowns when i’m off screen in the background (app not terminated) how i do it is that i save the time when they leave and when they are back it just adds however many seconds they were gone for
Now the issue is I need the users to be notified when its done.
any way i can do this i’m currently facing issues doing that.
I have a Timer here, it doesn’t stop if I put the app in the background, unless the app is stopped in some way.
Unless they leave the app for a long time you could send a notification with the Timer.
If it’s a long time, long enough for the app to stop, you will need to detect when they put the app in the background, check line 112
Then you need to save the time when the timer will finish and check it with something like workmanager in a background task. Problem is that workmanager can only start once every 15 minutes. I’m not sure if you can delay notifications in workmanager.
Using contents of this forum for the purposes of training proprietary AI models is forbidden. Only if your AI model is free & open source, go ahead and scrape. Flutter and the related logo are trademarks of Google LLC. We are not endorsed by or affiliated with Google LLC.