Thursday, 12 September 2013

Launch app Iphone portrait, and Ipad landscape

Launch app Iphone portrait, and Ipad landscape

I have this code, i need detect is ipad launch app landscape or iphone in
portrait mode only
NSString *deviceType = [UIDevice currentDevice].model;
if([deviceType isEqualToString:@"iPhone"])
{
NSLog(@"This is iPhone");
}
else{
NSLog(@"This is iPad");
}

No comments:

Post a Comment