我正在添加一個自定義註釋而不是針腳註釋。 基本上,我在這些註釋中畫一個圓圈並將它們添加到地圖中。 問題這些自定義註釋掩蓋了用戶位置視圖(藍點) 如何將藍點帶到前面。MKMapView:如何將MKUserLocationView(藍點)放在前面?
- (void)mapView:(MKMapView *)mapView didUpdateUserLocation:(MKUserLocation *)userLocation { UIView *user = [mapView viewForAnnotation:userLocation]; [mapView bringSubviewToFront:user]; }
但是,這不適用於我。藍色的用戶點仍在覆蓋我的自定義註釋。 任何想法如何讓用戶位置視圖出現在前面? 乾杯