简体   繁体   English

Windows 8桌面应用程序中的模拟位置

[英]Mock location in windows 8 desktop application

我正在使用Geolocator在Windows 8桌面应用程序中获取设备位置,有没有一种方法可以通过让OS通过设置模拟位置来模拟位置更改来对其进行测试?

Yes! 是!

Same as you would for a phone app, you need to run your app in the visual studio simulator. 与电话应用程序相同,您需要在Visual Studio模拟器中运行您的应用程序。

From there, you can change settings such as simulated location. 在这里,您可以更改设置,例如模拟位置。

See the guide here https://msdn.microsoft.com/library/windows/apps/hh441475(v=vs.120).aspx#BKMK_Set_the_simulated_geo_location_of_the_device 在此处查看指南https://msdn.microsoft.com/library/windows/apps/hh441475(v=vs.120).aspx#BKMK_Set_the_simulated_geo_location_of_the_device

You can use this tool https://github.com/juliankay/FakeGPS 您可以使用此工具https://github.com/juliankay/FakeGPS

FakeGPS is a Windows driver which allows the user to provide geolocation information without a physical GPS device. FakeGPS是Windows驱动程序,它使用户无需物理GPS设备即可提供地理位置信息。

I tried it and it works great. 我尝试了,效果很好。

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

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