Forcing an iPad app to show splitView even in Portrait orientation(Like the Settings iPad app)(强制 iPad 应用程序在纵向显示 splitView(如设置 iPad 应用程序))
问题描述
我正在尝试开发一个基于 splitView 的 iPad 应用程序,它可以在每个方向上显示拆分界面.我已经尝试按照 this 教程,但它不起作用.我尝试创建一个类别来设置 _hidesMasterViewInPortrait = (hidden) ?0 : 1;
,正如上述博客中的评论之一所建议的那样,但没有任何效果.
I am trying to develop a splitView based iPad app, that displays the split interface in every orientation. I have tried subclassing the UISplitViewController class as given in this tutorial, but it doesn't work. I tried creating a category to set _hidesMasterViewInPortrait = (hidden) ? 0 : 1;
, as suggested in one of the comments in the above blog, but nothing worked.
谁能在不使用任何第三方框架或类的情况下帮助我找到解决方法?
Can anyone help me to find a way out of this, without using any third party frameworks or classes?
推荐答案
我从来没有实现强制 SPlitViewController 这样做,但由于您需要为这两个部分创建控制器,您可以重用这些控制器以显示内容的方式你想要它.
I never achieved to force the SPlitViewController to do that but since you need to create controllers for both parts, you can just reuse those controllers to display the content the way you want it.
这篇关于强制 iPad 应用程序在纵向显示 splitView(如设置 iPad 应用程序)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:强制 iPad 应用程序在纵向显示 splitView(如设置 iPad 应用程序)


- SetOnItemSelectedListener上的微调程序错误 2022-01-01
- 网上有没有好的 UIScrollView 教程? 2022-01-01
- GPS状态的广播接收器? 2022-01-01
- 类似于 Mail.app 的 iPad 模态视图控制器? 2022-01-01
- 使用自动布局向 UIScrollView 添加动态大小的视图 2022-01-01
- URL编码Swift iOS 2022-01-01
- 如何在 iPhone 模拟器中重置 NSUserDefaults 数据? 2022-01-01
- 在 Iphone SDK 的导航栏上添加多个按钮 2022-01-01
- Xcode 7.3 中带有 UILabel 的 UIStackView 2022-01-01
- UITextView 内容插图 2022-01-01