本文整理汇总了Java中com.amap.api.maps.model.Marker.showInfoWindow方法的典型用法代码示例。如果您正苦于以下问题:Java Marker.showInfoWindow方法的具体用法?Java Marker.showInfoWindow怎么用?Java Marker.showInfoWindow使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.amap.api.maps.model.Marker
的用法示例。
在下文中一共展示了Marker.showInfoWindow方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: drawMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* 绘制系统默认的1种marker背景图片
*/
public void drawMarkers() {
Marker marker = aMap.addMarker(new MarkerOptions()
.position(
new LatLng(responseMessage.body.getPositionLatitude(),
responseMessage.body.getPositionLongitude()))
.title("好好学习")
.icon(BitmapDescriptorFactory
.defaultMarker(BitmapDescriptorFactory.HUE_AZURE))
.perspective(true).draggable(true));
marker.setRotateAngle(0);// 设置marker旋转90度
marker.showInfoWindow();// 设置默认显示一个infowinfow
aMap.animateCamera(CameraUpdateFactory.newLatLngZoom(
new LatLng(responseMessage.body.getPositionLatitude(),
responseMessage.body.getPositionLongitude()), 15));
}
示例2: drawMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* 绘制系统默认的1种marker背景图片
*/
public void drawMarkers() {
Marker marker = aMap.addMarker(new MarkerOptions()
.position(
new LatLng(mUrgentMessage.body.getPositionLatitude(),
mUrgentMessage.body.getPositionLongitude()))
.title("好好学习")
.icon(BitmapDescriptorFactory
.defaultMarker(BitmapDescriptorFactory.HUE_AZURE))
.perspective(true).draggable(true));
marker.setRotateAngle(0);// 设置marker旋转90度
marker.showInfoWindow();// 设置默认显示一个infowinfow
aMap.animateCamera(CameraUpdateFactory.newLatLngZoom(
new LatLng(mUrgentMessage.body.getPositionLatitude(),
mUrgentMessage.body.getPositionLongitude()), 15));
}
示例3: onMarkerClick
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {
if (marker.isInfoWindowShown()) {
marker.hideInfoWindow();
} else {
marker.showInfoWindow();
}
if (marker.equals(mWHU1)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU1.getPosition());
} else if (marker.equals(mWHU2)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU2.getPosition());
} else if (marker.equals(mWHU3)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU3.getPosition());
} else if (marker.equals(mWHU4)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU4.getPosition());
} else if (marker.equals(mWHU5)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU5.getPosition());
} else if (marker.equals(mWHU6)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU6.getPosition());
} else if (marker.equals(mWHU6)) {
endPoint = AMapUtil.convertToLatLonPoint(mWHU7.getPosition());
}
return false;
}
示例4: drawMarkers
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
public void drawMarkers(List<BuildingPoint> buildingPointList) {
for (int i = 0; i < buildingPointList.size(); i++) {
BuildingPoint point = buildingPointList.get(i);
MarkerOptions options = new MarkerOptions().position(point.getLatLng()).title(point.getBuildName());
options.snippet("停留" + (point.getTime() / 1000 / 60) + "分钟");
options.setFlat(true);
Marker marker = mAmap.addMarker(options);
marker.setInfoWindowEnable(true);
marker.showInfoWindow();
}
}
示例5: onMarkerClick
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {
// 显示marker点的信息
marker.showInfoWindow();
return true;
}
示例6: onMarkerClick
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {
if (marker.isInfoWindowShown()) {
marker.hideInfoWindow();
} else {
marker.showInfoWindow();
}
return false;
}
示例7: showInfoWindow
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
/**
* Show the InfoWindow for the passed Marker and ClusterPoint
*
* @param marker
* @param clusterPoint
*/
public void showInfoWindow(Marker marker, ClusterPoint clusterPoint) {
AMap map = mapRef.get();
if (map != null && marker != null && clusterPoint != null) {
long dirtyUntil = System.currentTimeMillis() + options.getShowInfoWindowAnimationDuration();
innerCallbackListener.clusteringOnCameraChangeListener.setDirty(dirtyUntil);
CameraUpdate cameraUpdate = CameraUpdateFactory.newLatLng(marker.getPosition());
map.animateCamera(cameraUpdate, options.getShowInfoWindowAnimationDuration(), new CancelableCallback() {
@Override
public void onFinish() {
innerCallbackListener.handler.post(new Runnable() {
@Override
public void run() {
innerCallbackListener.clusteringOnCameraChangeListener.setDirty(0);
}
});
}
@Override
public void onCancel() {
innerCallbackListener.clusteringOnCameraChangeListener.setDirty(0);
}
});
marker.showInfoWindow();
}
}
示例8: onMarkerClick
import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {
marker.showInfoWindow();
return false;
}