public void myClickHandler(View target) {
switch(target.getId()) {
/*case R.id.zoomin:
mapView.getController().zoomIn();
break;
case R.id.zoomout:
mapView.getController().zoomOut();
break;*/
case R.id.sat:
this.mapView.setSatellite(true);
break;
case R.id.street:
this.mapView.setStreetView(true);
break;
case R.id.traffic:
this.mapView.setTraffic(true);
break;
case R.id.normal:
this.mapView.setSatellite(false);
this.mapView.setStreetView(false);
this.mapView.setTraffic(false);
break;
default:
break;
}
// The following line should not be required but it is,
// at least up til Froyo.
this.mapView.postInvalidateDelayed(2000);
}
我相信你需要setStreetView,即使它說,它不贊成它的作品確定爲我
@Deprecated
public void setStreetView(boolean on)
Deprecated. Street view availability highlighting is no longer supported. This method operates as a no-op.
Control whether Street View availability (blue outlines) is shown on the map. This is incompatible with Traffic indicators, so they will be deactivated if necessary. Street View availability can be drawn over map tiles or over satellite tiles; however, they are optimized for map tiles.
感謝您的答覆。我們希望谷歌增加API的新功能,像setRoadMap(boolean on),這對我們非常有用。你知道如何通過電子郵件聯繫谷歌地圖查看工程師?我們想要問他們的幫助。順便說一句,我們還有其他選項只能用於衛星視圖嗎? – ADA 2012-02-28 03:13:33
仍未找到解決方案。這是未關閉的問題[http://code.google.com/p/android/issues/detail?id=22405](http://code.google.com/p/android/issues/detail?id=22405) – ADA 2012-04-13 07:49:06