百度地图标注的显示问题
正常情况下,点击地图上的大头针,标注会显示出来,点击地图上的空白处,标注会消失。
如果希望一进地图页面,标注就显示出来,并且一直都不消失应该怎么做呢?
首先在- (BMKAnnotationView *)mapView:(BMKMapView *)mapView viewForAnnotation:(id <BMKAnnotation>)annotation回调函数里设置
BMKPinAnnotationView的selected属性为yes,
然后在-(void)mapView:(BMKMapView *)mapView didDeselectAnnotationView:(BMKAnnotationView *)view回调函数里调用
/**
*选中指定的标注,本版暂不支持animate效果
*@param annotation 指定的标注
*@param animated 本版暂不支持
*/
- (void)selectAnnotation:(id <BMKAnnotation>)annotation animated:(BOOL)animated;

浙公网安备 33010602011771号