iPhone/iPad 屏幕旋屏 iphone / ipod deployment info 调整

一般新建一个ViewController都会默认有以下这个函数

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation;



下面我们来定义各种旋转

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation

{

return (interfaceOrientation == UIInterfaceOrientationPortrait); //只支持竖屏

//return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);  //除了倒置,其他方向都支持

//return (interfaceOrientation == UIDeviceOrientationLandscapeRight); //只支持向右横屏

//return (interfaceOrientation == UIDeviceOrientationLandscapeLeft);  //只支持向左横屏

}


如果不重写这个函数(也就是把这个函数完全注释),默认是只支持竖屏幕。





如果要在xib视图变成横屏,需要在Simulated Metrics的Orientation设置为Landscape。





如果让程序一启动就是横屏显示,就要在工程设置里的Summary的iPhone/iPod Deployment Info 改变 Supported Device Orientations 的选项



本文出自 “7087095” 博客,请务必保留此出处http://7097095.blog.51cto.com/7087095/1221220

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
Apress, 2010 Are you an IT professional involved in deploying the iPhone and or iPad in your company or organization? Do you have fellow employees who are eager to use their iPhones and iPads for work? Then this is the book for you. Enterprise iPhone and iPad Administrator’s Guide provides step-by-step instructions on how to deploy and integrate the iPhone within a range of professional environmentsâ?"from large businesses and educational institutions to medium-sized offices. This book ensures that the process is achieved in a streamlined, efficient, and cost-effective manner. The guide begins with an introduction to basic deployment concerns, then moves into actual methods and tools that you can use to streamline the deployment process. Next, an in-depth discussion of configuration and provisional profiles helps you deliver solid device setup, security, and adherence to organization policies. Finally, you’ll learn how to use existing help desk teams to provide effective user support. Also included is coverage of the latest iPhone- and iPad-specific enterprise technologies (such as push notification and calendaring tools) as well as internal iPhone and iPad applications and web-based solutions for businesses. What you’ll learn * Activate and deploy the iPhone and iPad (and iTunes if it will serve as a sync conduit for users). * Use the iPhone and iPad built-in client management capabilities. * Support iPhone- and iPad-specific services both inside and outside of a private network, provisioning security profiles and applications to users. * Provide effective user support, both in the office and in the field. Who this book is for This book is intended for IT staff members that will be charged with planning an iPhone and ipad implementation or pilot program, as well as those that will be charged with ultimately deploying and provisioning the devices and delivering support to iPhone and iPad users. Readers should have an existing background in IT management, systems administration, and end user support working in a medium to large business or enterprise environment. amazon link:http://www.amazon.com/exec/obidos/ASIN/1430230096/buythisbooks-20

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

杜甲同学

感谢打赏,我会继续努力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值