rekabhq / background_locator

A Flutter plugin for updating location in background.
MIT License
288 stars 329 forks source link

can't stop location service when bring service from background #194

Open tranice opened 3 years ago

tranice commented 3 years ago

Hi, when I take a running service to background by press back button and press notification icon to bring service to foreground , I found can't stop location service even I execute "BackgroundLocator.unRegisterLocationUpdate" serval times.
anyone has same problem? it occurs in android Emulator

mehdok commented 3 years ago

Hi @tranice

Thank you for opening an issue;

Are you testing the example app? if not please share some code;

tranice commented 3 years ago

Hi @mehdok I test the example app in Android Emulator - Pixel_2_XL_API_28 and Nokia 7 plus , both occurs. the step is: 1、press start 2、press back button, quit app 3、press notification bar to reenter app 4、press stop , still receive data.

mehdok commented 3 years ago

Thank you @tranice.

I can reproduce this problem, so it is officially a bug;)

Thanks for reporting, will notif you when it is fixed.

tranice commented 3 years ago

@mehdok you are welcome, thanks for your effort !

olryts commented 3 years ago

hi @mehdok , is this already fixed? thank you so much!

mehdok commented 3 years ago

@olryts Sadly no, it is not fixed yet;

FLavenNA commented 3 years ago

Hello i am facing an issue and i need your help. I want to get location once in a every 15 secs. Both IOS and Android. I can make it with interval settings in Android but i couldn't find a way for IOS. Is there a way to do this ?

mehdok commented 3 years ago

Hi @FLavenNA

It is better if you could open a new issue for your problem.

But short answer, there is no way to force iOS to use the interval to send location updates, iOS will send you updates whenever it receives one.