flutter_background_service
flutter_background_service copied to clipboard
Remove foreground notifiction after kill app
Hello.
how we can remove initial foreground notifiction when close app via swipe?
if the service is programmatically killed by invoking stopService it works but if the user himself removes apps from a recent app list there is no way to remove the notification from the bar Stuck with this problem
if the service is programmatically killed by invoking stopService it works but if the user himself removes apps from a recent app list there is no way to remove the notification from the bar Stuck with this problem
yea - may be need make some loop in service that will ask main app and if no response kill yourself?
Well, my solution - app send heartbeat(using dart:async:Timer) message to foreground service each 10 sec and if service don`t receive this message in other 10 sec - kill yourself.
@rsulab , can you give me example?Currently i am facing same issue.