2010-06-08 29 views
0

我將此添加到我的代碼再轉動時,即時通訊初始化電影Movieplayer doenst當我用setControlStyleNone

[m_pMPmpc.movi​​ePlayer setControlStyle:MPMovieControlStyleNone]。

其中m_pMPmpc是MPMoviePlayerViewController

它工作得很好,但後來我發現,電影犯規旋轉了同時播放(但看完電影后的應用程序仍然旋轉),但它檢測到的方向開始和遵循。

我需要將其設置爲在播放時遵循風景方向。任何想法添加什麼代碼?

回答

0

嘗試創建MPMoviePlayerViewController的類子級,並在方向爲橫向時覆蓋shouldAutorotateToInterfaceOrientation以返回yes。實例化您的類,而不是默認的MPMoviePlayerViewController。

它適用於我。

相關問題