In iOS7, UIViewController
has a new property preferredContentSize
. A project made for iOS7 has the following method:
- (void)awakeFromNib
{
self.preferredContentSize = CGSizeMake(320.0, 480.0);
[super awakeFromNib];
}
It therefore sends a setPreferredContentSize:
message to your own controller, no matter if the property is implemented or not. To resolve the issue, you might want to avoid setting a property that does not exist:
- (void)awakeFromNib
{
if ([[[UIDevice currentDevice] systemVersion] compare:@"7" options:NSNumericSearch] != NSOrderedAscending) {
self.preferredContentSize = CGSizeMake(320.0, 480.0);
}
[super awakeFromNib];
}