Send data from one activity to another regularly

前端 未结 1 1522
[愿得一人]
[愿得一人] 2021-01-17 01:30

I get my location in Main Activity regularly by Fused Location Provider each 30 seconds. I don\'t use service or anything else. i get location just when user is in applicati

相关标签:
1条回答
  • 2021-01-17 01:54

    There's only one activity active and running at any time. You might be better off with 2 fragments or just an additional MapView in your MainActivity which you can make visible or gone, instead of having different activities.

    Or you use a service, which can run in the background in parallel to any of your Activities.

    0 讨论(0)
提交回复
热议问题