现象:代码在simulator上能够正常运行但是在真机上出现
Assertion failure in -[UIView layoutSublayersOfLayer:], /SourceCache/UIKit/UIKit-2935.137/UIView.m:8803
(ios7系统)
解决方法: 在layoutSublayersOfLayer中调用> [self.view layoutSubviews];
- (void)layoutSublayersOfLayer:(CALayer *)layer {
[self layoutSubviews];
}