如何用UIInterfaceOrientationLandscapeLeft初始化UIViewController?

问题描述:

我有一个从UIViewController继承的WebViewController,也使用shouldAutorotateToInterfaceOrientation。如何用UIInterfaceOrientationLandscapeLeft初始化UIViewController?

目前为止还不错,但是当我切换到WebViewController时,则以纵向模式启动。只有当我打开iPhone时,它才开始旋转。

现在任何想法如何开始在UIInterfaceOrientationLandscapeLeft?

THX

请看看this tutorial - 它应该解决您的问题。

基本上,您必须在Info.plist文件中添加一个密钥UIInterfaceOrientation,其值为UIInterfaceOrientationLandscapeLeft

+0

链接不起作用 – Rodrigo 2011-08-03 16:18:54

+0

已经差不多2年了......更新了。 – 2011-08-04 06:36:04