Xcode when I run the program on the iphone 5 screen it looks like iphone 4
I am using Xcode 6 and using objective-c when the iOS 8 (iPhone 5) program starts without error, but when I try to test the program on the iOS 7 (iPhone 5) screen it looks like the iPhone 4 screen. I can detect a phone like this:
#define iPhone6Plus ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone && [UIScreen mainScreen].bounds.size.height == 736)
#define iPhone6 ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone && [UIScreen mainScreen].bounds.size.height == 667)
#define IS_IPHONE_5 ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone && [UIScreen mainScreen].bounds.size.height == 568)
#define IS_IPAD UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad
and also i can detect the operating system like this:
if (floor(NSFoundationVersionNumber) <= NSFoundationVersionNumber_iOS_7_0)
{
#define IS_IPHONE_5 ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone && [UIScreen mainScreen].bounds.size.height == 568)
}
When I make this screen non-scalable on the phone, because when I run on the phone screen of iOS 7, run like iPhone 4, check the image for a more detailed description.
As you can see the top and bottom are black. How can I fix this problem.
+3
source to share