【发布时间】:2017-08-09 11:20:06
【问题描述】:
我正在使用此代码在 android 中打开 Google 地图应用。
if(source != null && destination != null) {
Intent intent = new Intent(android.content.Intent.ACTION_VIEW,
Uri.parse("http://maps.google.com/maps?daddr="
+ destination.latitude + "," + destination.longitude + "(" + ADDRESS + ")"));
startActivity(intent);
} else {
Toast.makeText(context, "Please check your internet connection and try again!!", Toast.LENGTH_LONG).show();
}
当它进入 android 的谷歌地图应用程序时会发生什么,起初它在目标框中显示地址,在源框中显示“您的位置”,但之后,它变为“地图上的点”。有什么办法可以避免这种情况吗?还是我遗漏了什么?
谁能帮我解决这个问题?
【问题讨论】:
-
我遇到了同样的麻烦,在目的地,一开始它会显示我们提供的确切标签,然后它会自动替换为实际地址。你解决了这个问题吗?
标签: android google-maps android-googleapiclient