我使用需要被允许,以适应iPhone 5的屏幕,但是我似乎无法得到正确的布局视图帮助,我已经尝试了这一点;与iPhone 5视图布局
if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone)
{
if (IS_IPHONE5) {
NSLog(@"iPhone 5");
[SelectionPhotoOptionView setFrame:CGRectMake(470, 0, 640, 568)];
[SelectionButView setFrame:CGRectMake(0, 0, 640, 568)];
[imageViewSelection setFrame:CGRectMake(0, 0, 640, 568)];
[imageViewPhotoOption setFrame:CGRectMake(-470, 0, 640, 568)];
ButtonYpos=612;
} else {
NSLog(@"iPhone 4 and Lower");
[SelectionPhotoOptionView setFrame:CGRectMake(470, 0, 320, 480)];
[SelectionButView setFrame:CGRectMake(0, 0, 320, 480)];
[imageViewSelection setFrame:CGRectMake(0, 0, 320, 480)];
[imageViewPhotoOption setFrame:CGRectMake(-470, 0, 320, 480)];
ButtonYpos=412;
}
顶部是错误的,iPhone 5是不是制定了正确的,我不知道是否有人能帮助我了一个更简洁的代码示例使用?
谢谢, 克里斯