简体   繁体   English

Android获得Google Maps的最后已知位置

[英]Android get last known position of Google Maps

When the user opens up Google Maps on their phone, it immediately shows the position at which it was left during the last use. 当用户在手机上打开Goog​​le Maps时,它会立即显示上次使用时的位置。 What I'd like to do is "steal" the last known position of the map from the Google Maps program that comes with the phone, and position the map in my program that way. 我想做的是从手机随附的Google Maps程序中“窃取”地图的最后一个已知位置,并以此方式将地图定位在我的程序中。 I do not want to use the location feature. 我不想使用位置功能。 Is there any way to do this? 有什么办法吗?

Any help is appreciated, thanks. 任何帮助表示赞赏,谢谢。

-tjw -tjw

您仍然需要征求权限,但是Android 2.2的被动提供程序应该在不使用实际GPS或网络本身的情况下从其他提供程序返回结果,从而使您可以从Google Maps搭载结果。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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