iOS 适配iPhone5开发小结:(多出来88个点)
1.只支持iOS 6 可以使用自动布局;
2.界面设计是:顶部+表格+底部 可以快速匹配;
3.设计师:订制什么控件,同时适配4 and 5
#define IS_IPHONE_5 ( fabs( ( double )[ [ UIScreen mainScreen ] bounds ].size.height - ( double )568 ) < DBL_EPSILON ) 判断是否是iPhone5
view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; 自动向两边和上下填充
[[UIScreen mainScreen] bounds] 返回当前的height
在viewdidLoad()中添加:
CGRect frame=self.view.frame;
frame.size.height = [[UIScreen mainScreen ] bounds].size.height-20;
[self.view setFrame:frame];
相关文章:
http://www.cnblogs.com/maxfong/archive/2012/10/04/2711379.html
本文总结了iOS适配iPhone5开发过程中的关键点,包括界面设计、控件定制及代码实现技巧,帮助开发者高效完成适配工作。
2020

被折叠的 条评论
为什么被折叠?



