开发者

Ipad Interface Orientation Problem

开发者 https://www.devze.com 2023-02-19 01:13 出处:网络
For the moment I test my application on the simulator. I have an appDelegate and in this delegate I have several controllers that I want to use.

For the moment I test my application on the simulator. I have an appDelegate and in this delegate I have several controllers that I want to use. The First one, that I display, is a view which show that the application is loading. And when it's loaded I want to display another view. To display this new view I use an animation but it doesn't work 开发者_JAVA技巧well. In fact during the animation the new view is display in a portrait mode and when the animation finishes it move to a landscape mode. Nevertheless in my info.plist I allow landscape only and in all my .xib file all of my view are in landscape mode.

So I don't understand why this animation keep on displaying my view in a portrait mode.

Have Someone an idea about this problem? Thanks


You're probably trying to show the animation too early. You shouldn't be driving this process from the app delegate. Your initial interface should load by way of a UIViewController that provides the root view. When that UIViewController gets didRotateFromInterfaceOrientation: for the first time, the interface has finished loading and rotating into landscape mode and you're ready to rock and roll.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号