简体   繁体   中英

Location Updates in Background Android 10

我曾与https://github.com/android/location-samples (待定意向)合作过,everythink 适用于旧设备(24 级),但后台服务在 android 10 上不起作用。你有什么想法吗为什么呢?

The reason is Background Execution Limits on the all android version that have API level 26 or greater.

In order to provide user more better battery life and performance. Google started restrictions. now if application is not foreground then background service will not work. you have to make service as a foreground service that will always notify user that your app is running in background.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM