MPMoviePlayerController re-orientation portrait to landscape and back to portrait (iOS 4.1)

后端 未结 2 937
梦毁少年i
梦毁少年i 2020-12-14 07:26

Since iOS 3.2 the MPMoviePlayerController class allows to embed a movie in the view hierarchy. Now I\'m facing this issue: I create my portrait view by placing an instance

相关标签:
2条回答
  • 2020-12-14 07:59

    Check this out: MPMoviewPlayerController fullscreen playback rotation with underlying UIViewController with portrait mode only (rotation disallowed)

    Maybe a little different problem, but solution may be the same.

    0 讨论(0)
  • 2020-12-14 08:07

    You can use a separate view controller for MPMovieplayer. You don't have to override the

    (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation

    in the original view controller.

    if you are using MPMoviePlayerViewController, everything is already set nicely for you, as the method shouldAutorotateToInterfaceOrientation: will return YES by default. You can use it as a subview or present it modally by calling
    presentMoviePlayerViewControllerAnimated:

    0 讨论(0)
提交回复
热议问题