Reputation: 579
I just try to test my App. On iPhone and iPad and I found there are incorrect screen width/height issue on iPad Air.
Note:
CGRect screenBounds = [UIScreen mainScreen].bounds ;
CGFloat width = CGRectGetWidth(screenBounds) ;
CGFloat height = CGRectGetHeight(screenBounds) ;
From above code: width=320 and height=480 from my console
I use following code to test the width/height in iPad Air and iPhone
CGFloat width = 320.0;
CGFloat height = 480.0;
CGSize size = [UIScreen mainScreen].bounds.size;
CGPoint centerPoint = CGPointMake(size.width/2 - width/2, size.height/2 - height/2);
UIBezierPath* path = [UIBezierPath bezierPathWithRect:CGRectMake(centerPoint.x, centerPoint.y, width, height)];
_rectLayer.lineWidth = 2.0f;
_rectLayer.strokeColor = [[UIColor redColor] CGColor];
[_rectLayer setFillColor:[[UIColor clearColor] CGColor]];
[_rectLayer setPath:[path CGPath]];
[_rectLayer setOpacity:0.5];
[self.view.layer addSublayer:_rectLayer];
iPad Air, Red edge is not shown on top
iPhone 4s, red edge is shown everywhere
iPhone 5, red edge is shown everywhere
Upvotes: 0
Views: 624
Reputation: 318904
Your app is an iPhone-only app. Note the 1x/2x in the bottom-right corner of the iPad screen. If you want to support the full iPad screen, you need to make your app a universal app. In Xcode, select your target. Then go to the General tab. Change the Devices setting from iPhone to Universal.
Based on your iPhone screenshots, you have not supplied the proper launch images or a Launch Screen File (the latter is better).
Without these two changes, your app only supports 3.5" iPhones (which won't be accepted by Apple).
Upvotes: 2