PortraitとPortraitUpsideDownを回転させたいタブバーアプリケーションがあります。他のすべてのタブは問題なく、回転しています。唯一の違いは、ビューが xib も設計していることです。
これは、オリエンテーションをサポートするために実装するコードです。前に述べたように、他のすべてのタブが機能し、回転しています。
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation{
return (interfaceOrientation == UIInterfaceOrientationPortrait || interfaceOrientation == UIInterfaceOrientationPortraitUpsideDown);
}
- (BOOL)shouldAutorotate {
return [self shouldAutorotateToInterfaceOrientation:self.interfaceOrientation];
}
- (void)viewDidLoad{
self.view.autoresizesSubviews = YES;
self.view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
}
私のアプリは 4.3+ IOS をサポートしています。修正を手伝ってください-できるだけ早くAppleに送信する必要があります...