我正在使用地图v2。当用户点击标记时,我想用动画更改相机位置。
但是当我使用下面的功能并点击标记时,不会显示该标记的标题! (只需更换相机)。
@Override
public boolean onMarkerClick(Marker v) {
// TODO Auto-generated method stub
CameraPosition cameraPosition = new CameraPosition.Builder()
.target(v.getPosition()) // Sets the center of the map to Mountain View
.zoom(13) // Sets the zoom
.bearing(45) // Sets the orientation of the camera to east
.tilt(10) // Sets the tilt of the camera to 30 degrees
.build(); // Creates a CameraPosition from the builder
googleMap.animateCamera(CameraUpdateFactory.newCameraPosition(cameraPosition));
return true;
}