- Add iPadPro

- Add DeviceInches for Simulator
This commit is contained in:
Giuseppe Nucifora 2016-01-19 17:42:05 +01:00
parent 562a7c4582
commit ec59f2a93f
21 changed files with 187 additions and 21 deletions

View File

@ -467,7 +467,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
@ -500,7 +500,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;

View File

@ -5,16 +5,31 @@
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "29x29",
@ -44,6 +59,11 @@
"idiom" : "ipad",
"size" : "76x76",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
}
],
"info" : {

View File

@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

@ -1,23 +1,53 @@
{
"images" : [
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-Portrait-736h@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "Default-Landscape-736h@3x.png",
"minimum-system-version" : "8.0",
"orientation" : "landscape",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "667h",
"filename" : "Default-667h@2x.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "retina4",
"extent" : "full-screen",
"filename" : "Default-568h@2x.png",
"minimum-system-version" : "7.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad~nostatusbar.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
@ -25,6 +55,7 @@
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape~nostatusbar.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
@ -32,6 +63,7 @@
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad~nostatusbar@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
@ -39,9 +71,88 @@
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape~nostatusbar@2x.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default@2x.png",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default-568h@2x.png",
"extent" : "full-screen",
"subtype" : "retina4",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad.png",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad~nostatusbar.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape.png",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape~nostatusbar.png",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad@2x.png",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"filename" : "Default~ipad~nostatusbar@2x.png",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape@2x.png",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"filename" : "Default~ipad~landscape~nostatusbar@2x.png",
"extent" : "full-screen",
"scale" : "2x"
}
],
"info" : {

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

View File

@ -30,6 +30,8 @@
<array>
<string>armv7</string>
</array>
<key>UIRequiresFullScreen</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>

View File

@ -73,6 +73,13 @@ typedef NS_ENUM(NSUInteger, UIDeviceModelInches) {
UIDeviceModelInches79,
UIDeviceModelInches97,
UIDeviceModelInches129,
UIDeviceSimulatorModelInches35 = UIDeviceModelInches35,
UIDeviceSimulatorModelInches4 = UIDeviceModelInches4,
UIDeviceSimulatorModelInches47 = UIDeviceModelInches47,
UIDeviceSimulatorModelInches55 = UIDeviceModelInches55,
UIDeviceSimulatorModelInches79 = UIDeviceModelInches79,
UIDeviceSimulatorModelInches97 = UIDeviceModelInches97,
UIDeviceSimulatorModelInches129 = UIDeviceModelInches129,
UIDeviceModelInchesUnKnown
};

View File

@ -331,42 +331,62 @@
case UIDeviceGenerationModeliPad4:
case UIDeviceGenerationModeliPadAir:
case UIDeviceGenerationModeliPadAir2:{
return UIDeviceModelInches97;
}
break;
case UIDeviceGenerationModeliPadMini1:
case UIDeviceGenerationModeliPadMini2:
case UIDeviceGenerationModeliPadMini3:
case UIDeviceGenerationModeliPadMini4:
{
case UIDeviceGenerationModeliPadMini4:{
return UIDeviceModelInches79;
}
break;
case UIDeviceGenerationModeliPadPro:{
return UIDeviceModelInches129;
}
case UIDeviceGenerationModeliPadSimulator:{
}
break;
}
case UIDeviceGenerationModeliPadSimulator:
case UIDeviceGenerationModeliPhoneSimulator:{
CGRect screenRect = [[UIScreen mainScreen] bounds];
NSInteger screenWidth = (NSInteger)screenRect.size.width;
NSInteger screenHeight = (NSInteger)screenRect.size.height;
NSInteger screenHeight = ((NSInteger)screenRect.size.height > (NSInteger)screenRect.size.width) ? (NSInteger)screenRect.size.height : (NSInteger)screenRect.size.width;
switch (screenHeight) {
case 480:
case 480:{
return UIDeviceSimulatorModelInches35;
}
break;
case <#expression#>:
default:
case 568:{
return UIDeviceSimulatorModelInches4;
break;
}
case 667:{
return UIDeviceSimulatorModelInches47;
break;
}
case 736:{
return UIDeviceSimulatorModelInches55;
break;
}
case 1024:{
return UIDeviceModelInches97;
break;
}
case 1366:{
return UIDeviceSimulatorModelInches129;
break;
}
default:{
return UIDeviceModelInchesUnKnown;
break;
}
}
break;
}
default: {
return UIDeviceModelInchesUnKnown;
break;
default:
break;
}
}
return UIDeviceModelInchesUnKnown;
}