UIDeviceOrientationPortrait 및 UIDeviceOrientationLandscapeLeft를 지원하는 iPad 앱이 있습니다.iPad를 landscaperight 방향으로 강제로로드하는 방법?
나는이 방법을 포함했다 :
- (BOOL)shouldAutorotateToInterfaceOrientation:
(UIInterfaceOrientation)interfaceOrientation
{
return (interfaceOrientation == UIInterfaceOrientationPortrait ||
interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
}
내가 가진 문제는 내 UI 컨트롤이 제대로 설치 될 것입니다 때문에, 그냥 부하를 들어, UIDeviceOrientationLandscapeLeft 모드에서로드 할 필요는 것이다. 어떻게해야 부하에 한 번만 강제로 할 수 있습니다.
한 가지의 I 싶어 노트는이 분 아이폰 OS 프로젝트 설정이나 정보 파일 5.
하지만이 코드에서 실제로 상태 표시 줄을 가로에서 세로로 회전시킬 수 있습니까? 또는 반대 Versa (당신의 시나리오에 따라) – Huang
나는이 솔루션을 시도했지만 (상태 표시 줄의 방향을 바꾼 변형), 나에게는 효과가 없었고, 당신은 herre ein을 읽을 수 있었고, alsways는 작동하지 않는다. 어떤 안정적인 솔루션도 존재하지 않습니다. 그런데, statusBar의 방향을 바꾸는 것을 잊었습니까? – AlexWien
내 편집 내 대답을 확인, 내 애플 리케이션 에서이 작업 코드가있다 shouldautoRotate가 NO로 설정되어 있고 preferredInterfaceOrientation이 landscapeleft 인 경우 새로운 viewcontroller를 표시하는 동안 modalViewController를 추가하고 viewWillAppear 내에서이를 삭제하면 트릭을 수행한다. – nsgulliver