我在iPhone 4中有一個應用程序,工作正常。現在我想將它遷移到5.我有一個startupviewcontroller用xib顯示飛濺圖像; xib是在Xcode 4.2中生成的,所以它有一個320 480的框架視圖和一個圖像視圖添加到它的圖像。現在我希望所有這些都可以在iPhone 5中工作。對於我改變了圖像大小被添加到高於640 * 960.And所使用的一個圖像視圖640 * 1136我加入遷移到iphone5無法正常工作?
if([[UIScreen mainScreen] bounds].size.height == 480)
{
[self.view setFrame:CGRectMake(0,0,320,480)];
}
else
{
[self.view setFrame:CGRectMake(0,0,320,568)];
backgroundimage.image=[UIImage imageNamed:@"[email protected]"];
}
不工作。圖像後底部給了我一些空白空間。我也嘗試了自動調整掩碼。這也沒有奏效。
誰能救我出這挖的?