1) Select the main view, set the background color to black (or whatever color you want the status bar to be

2) Make sure the background is a self contained subview positioned as a top level child of the controller's view.
Move your background to become a direct child of the controller's view.
Check the autosizing panel to be sure that you've locked all frame
edges, activated both flexibility axes, and if this is a UIImageView,
set the content mode to Scale to fill. Programmatically this
translates to contentMode set to UIViewContentModeScaleToFill and has
its auto resizing mask set to (UIViewAutoresizingFlexibleWidth |
UIViewAutoresizingFlexibleHeight).

3) Now move everything that is locked to the top - down by 20 pts and set a iOS 6/7 delta Y to -20.
All top level children that are locked to the top frame in the
autosizing panel need to be moved down by 20pts and have their iOS 6/7
delta Y set to -20. (Cmd select all of those, and click down arrow 20
times - is there a better way anyone?)

4) Adjust the iOS 6/7 delta height of all of the above items that had a flexible height.
Any of the items that were locked to the frame top and bottom and had
flexible height enabled in the autosizing panel must also have their iOS
6/7 delta height set to 20. That includes the background view
mentioned above. This may seem anti-intuitive, but due to the order in
which these are applied, it is necessary. The frame height is set first
(based on device), then the deltas are applied, and finally the
autosizing masks are applied based upon the offset positions of all of
the child frames - think it through for a bit, it will make sense.

5) Finally, items that were locked to the bottom frame but not the top frame need no deltas at all.

That will give you the identical status bar in iOS7 and iOS6.

On the other hand, if you want iOS7 styling while maintaining iOS6 compatibility, then set the delta Y / delta height values to 0 for the background view.

To see more iOS7 migration info read the full post: http://uncompiled.blogspot.com/2013/09/legacy-compatible-offsets-in-ios7.html

最新文章

  1. e.Tomcat中的sendfile支持
  2. JAVA CAS原理深度分析
  3. 对tomcat来说,每一个进来的请求(request)都需要一个线程,直到该请求结束。
  4. Cocos2d-x 3.0 红孩儿私家必修 - 第二章 cpp-empty-test
  5. 【BZOJ3211】【并查集+树状数组】花神游历各国
  6. Linq 实现普通sql中 where in 的功能
  7. C#识别图片上的数字
  8. 调整ORACLE用户关闭密码有效期
  9. iOS扩展——Objective-C开发编程规范
  10. 第六十三天 js基础
  11. kubernetes 利用label标签来绑定到特定node运行pod
  12. MyBatis简单使用和入门理解
  13. Linux将未挂载的磁盘挂载到目录
  14. @RequestBody
  15. hdu 2444 The Accomodation of Students 【二分图匹配】
  16. django ajax增 删 改 查
  17. 【MYSQL】主从常见问题运维
  18. Linux系统 Centos6 安装
  19. AT1984 Wide Swap
  20. Pychram------更改编辑区域的字体大小和背景颜色

热门文章

  1. SiteMesh2-示例工程
  2. 两张图让git新手在项目中运用git命令行
  3. 国内APP漏洞扫描收费情况调查
  4. MAC Wireshark抓包IOS
  5. iOS UITextView 高度随文字自己主动添加,并尾随键盘移动(二)
  6. Codeforces Round #311 (Div. 2)A Ilya and Diplomas
  7. 技术架构model
  8. BitmapFactory.decodeStream()获取bitmap返回null
  9. 【POJ 1845】 Sumdiv
  10. [HNOI2006]潘多拉的宝盒