내 문제는 iPad에서만 발생합니다. 항상 렌더링되지 않은 MKMapView 부분 (오른쪽 그림)이 있습니다. 이 창을 터치하자마자 mapview가 잘 돌아 간다. 그러나 결코 올바르게 렌더링되지 않습니다. 이 문제는 시뮬레이터 및 장치의 iOS 4.2뿐만 아니라 iOS 4.2에서도 발생합니다. MKMapView를 구성 코드는 바로 다음과 같습니다 :iPad의 MKMapView 렌더링 문제
- (void)viewDidLoad {
[super viewDidLoad];
mapview = [[[MKMapView alloc] initWithFrame:CGRectMake(0,0,self.view.frame.size.width,230)] autorelease]; // because of apples bug
mapview.autoresizingMask = UIViewAutoresizingFlexibleWidth;
MKCoordinateSpan globe = MKCoordinateSpanMake(100, 100);
CLLocationCoordinate2D worldCenter; worldCenter.latitude = 42.032974; worldCenter.longitude =21.359375;
MKCoordinateRegion worldmap = MKCoordinateRegionMake(worldCenter, globe);
mapview.region = worldmap;
mapview.zoomEnabled = NO;
mapview.showsUserLocation = YES;
mapview.delegate = self;
NSRange theRange;
theRange.location = 1;
theRange.length = [annotations count]-1;
[mapview addAnnotations:[annotations subarrayWithRange:theRange]];
[self.view addSubview:mapview];
}
에만 문제가 가로 방향으로 자체 명단.
UPDATE
내가보기를 만진 후에는 걸쳐 방법이있다.
이 보인다? 멀리 볼 수있는 화면의 오른쪽에 '왼쪽'으로 렌더링 할 수있는지도가 없습니다. 즉, 세계의 끝입니다.) - 문제가 해결되었는지 스팬 값으로 확인해보십시오. – Rog
@Rog이 뷰를 터치하자마자 렌더링이 잘됩니다. 지구의 고도를 클리핑하여 자동으로 크기를 조정하기 때문에 항상 충분한 세계관이 있습니다. – bioffe
화면을 터치하고 다시 렌더링 할 때 오른쪽에서 무엇을 볼 수 있습니까? 나는지도 앱에서 내 최대 축소를 시도했고 오른편은 위에 게시 한 내용과 일치하므로 궁금합니다!? – Rog