当前位置: 首页>>代码示例>>Java>>正文


Java Marker.showInfoWindow方法代码示例

本文整理汇总了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));
}
 
开发者ID:chenbocong,项目名称:FamilyLink,代码行数:19,代码来源:MapActivity.java

示例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));
}
 
开发者ID:chenbocong,项目名称:FamilyLink,代码行数:19,代码来源:AlarmActivity.java

示例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;
}
 
开发者ID:flsf,项目名称:WHUMap,代码行数:25,代码来源:MyMapFragment.java

示例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();
    }
}
 
开发者ID:stdnull,项目名称:RunMap,代码行数:12,代码来源:MapDrawer.java

示例5: onMarkerClick

import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {

    //  显示marker点的信息
    marker.showInfoWindow();

    return true;
}
 
开发者ID:zhuyu1022,项目名称:amap,代码行数:9,代码来源:AmapManager.java

示例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;
}
 
开发者ID:Tsroad,项目名称:Road,代码行数:10,代码来源:RouteActivity.java

示例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();
	}
}
 
开发者ID:mikezit,项目名称:cluster-amap,代码行数:35,代码来源:Clusterkraf.java

示例8: onMarkerClick

import com.amap.api.maps.model.Marker; //导入方法依赖的package包/类
@Override
public boolean onMarkerClick(Marker marker) {
	marker.showInfoWindow();
	return false;
}
 
开发者ID:Tsroad,项目名称:Road,代码行数:6,代码来源:PoiKeywordSearchActivity.java


注:本文中的com.amap.api.maps.model.Marker.showInfoWindow方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。