0

ルート ビューは UIImage ビューであり、サブビューがあり、サブビューがあります。私のルート ビューはランドス ケープで開きます。プロジェクトの .plist で両方のプロジェクト プロパティを設定し、application.statusBarOreintation を applicationDidFinishLaunching に統合して、それが機能することを確認しました。

しかし、私のサブビューはすべて縦に表示されています。サブビューでこれを変更するにはどうすればよいですか?

ありがとう // :)

4

1 に答える 1

1

ビューコントローラーはありますか?shouldAutorotateToInterfaceOrientation は何を返しますか?

// Override to allow orientations other than the default portrait orientation.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
    // Return YES for supported orientations
    return ((interfaceOrientation == UIInterfaceOrientationLandscapeLeft) || 
            (interfaceOrientation == UIInterfaceOrientationLandscapeRight));
}

ビューコントローラーがないと、ロードする各ビューを回転させるために変換を適用する必要があります。

于 2009-09-04T21:41:23.377 に答える