여기에 질문이 있습니다. 나는하려고하고있다.mkmapview showsUserLocation
if (Map.showsUserLocation == YES)
{
Map.showsUserLocation = NO;
}
이것은 다소 간단합니다. 앱이 방금 시작한 때 showsUserLocation
이 YES로 설정되었지만 기기가 위치를 찾는데 시간이 걸립니다. 따라서 사용자가 위치를 찾기 전에 (파란색 점이 나타나기 전에) showsUserLocation = NO
을 클릭하면 EXC_BAD_ACCESS.
Google지도에서 보호 코드가 있습니다. Google지도가 파란색 점을 표시하기 전에 activityIndicator를 표시하여 showsUserLocation
버튼을 누르지 못하도록합니다. 어떻게해야할까요? 미리 감사드립니다.
- (void)mapView:(MKMapView *)mapView didUpdateUserLocation:(MKUserLocation *)userLocation
당신은 그때까지 비활성 상태를 유지, 여기에 버튼을 활성화 할 수 있습니다
나는 완전히 이해하지 못했습니다. 뭐하고 싶어??? – alecnash