您的位置:首页 > 产品设计 > UI/UE

IOS UI问题集

2015-06-29 15:13 387 查看
启动动画的尺寸大小:

LaunchImage320x480.png

LaunchImage640x960.png

LaunchImage640x1136.png

[转载]ios 开发 icon图标设置

iPhone屏幕尺寸、分辨率及适配





一、ios横竖屏适配解决方案

#pragma mark - 竖屏设置
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
NSLog(@"%s",__FUNCTION__);
if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
if (interfaceOrientation == UIInterfaceOrientationPortrait)
{
Landscape=NO;
return (interfaceOrientation == UIInterfaceOrientationPortrait);
} else if (interfaceOrientation == UIInterfaceOrientationLandscapeLeft)
{
Landscape=YES;
return (interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
}else if (interfaceOrientation == UIInterfaceOrientationLandscapeRight)
{
Landscape=YES;
return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
}

return NO;

}else {
return YES;
}
}

- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration
{
if (toInterfaceOrientation == UIInterfaceOrientationPortrait)
{
Landscape=NO;
} else if (toInterfaceOrientation == UIInterfaceOrientationLandscapeLeft)
{
Landscape=YES;
}else if (toInterfaceOrientation == UIInterfaceOrientationLandscapeRight)
{
Landscape=YES;
}
NSLog(@"%s Landscape:%@",__FUNCTION__,Landscape==YES?@"YES":@"NO");

}

//iOS 7 适配
- (NSUInteger)supportedInterfaceOrientations
{
NSLog(@"%s",__FUNCTION__);
return UIInterfaceOrientationMaskAll;
}

- (BOOL)shouldAutorotate
{
NSLog(@"%s",__FUNCTION__);
return YES;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: