2

シミュレーターを縦向きから横向きに回転すると、ヘッダーが回転しません。UIInterfaceOrientation を使用してビューの回転に合わせてヘッダーを回転させたい。ここに画像の説明を入力

4

1 に答える 1

1

@renuga ビューコントローラーにこのメソッドを実装する必要があると思います。

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation
{
    if(toInterfaceOrientation == UIInterfaceOrientationLandscapeRight)
        return YES;
    if(toInterfaceOrientation == UIInterfaceOrientationPortrait)
        return YES;
    return NO;
}

IB に移動し、下に示す矢印をクリックします。

ここに画像の説明を入力

そこで、タブバーの位置を調整する必要があります

于 2011-02-15T07:08:19.170 に答える