1
我的應用程序是在橫向模式下,我使用的MPMoviePlayerController發揮樣本視頻。它工作正常,但是當我停止與OK按鈕的視頻(或者,如果我等到電影結束),方向自動切換到肖像。 是否有可能保持在橫向模式下的應用程序時確定按鈕被按下?iPhone禁止應用自動改變方向爲縱向當視頻停止
我用followwing代碼在我的主視圖控制器,迫使風景模式:
-(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
}