2016-10-25 85 views
0

我有一个应用程序,我已经从项目设置锁定到肖像模式。也应该旋转是错误等。在模拟器(和设备),当我在iPhone设备上,并旋转标签和视图留在他们的地方。但在iPad上,当我改变景观时,尝试重新排列视图。这是为什么发生?谢谢。iPhone和iPad肖像模式应用程序不同的反应

+0

检查从这里接受的答案:http://stackoverflow.com/questions/29664441/different-device-orientation-according-到设备-iphone或 - ipad的 –

回答

0

正如马修说,尝试这样的事情

继@ScarletMerlin的建议,改变了钥匙在info.plist中,在我看来,因为我有满足要求的最佳解决方案(固定的定向类型各种设备)。

下面是我使用的设置的打印屏幕。也许它可以帮助其他类似怀疑的开发者。

Settings in info.plist file

的relavent源代码如下所示:

<key>UISupportedInterfaceOrientations</key> 
<array> 
    <string>UIInterfaceOrientationPortrait</string> 
</array> 
<key>UISupportedInterfaceOrientations~ipad</key> 
<array> 
    <string>UIInterfaceOrientationLandscapeLeft</string> 
    <string>UIInterfaceOrientationLandscapeRight</string> 
</array> 
相关问题