iPad iPhone程序增加和删除启动画面

原文地址:http://blog.csdn.net/dabiaoyanjun/article/details/8158729

1、使用方式

直接拖放到程序目录下面就可以了: 
Default.png            iPhone默认启动图片,     320x480或者320x460
Default@2x.png         iPhone4启动图片         640x960或者640x920

2、为iPad和iPhone程序增加启动画面非常简单,基本思路就是增加启动图片资源Default.png即可,只是要根据不同的分辨率和旋转方向需要有不同的图片尺寸。
目前的iOS设备有三种不同的分辨率:

[plain] view plaincopy
 
  1. 1 iPad  
  2.  768x1024  
  3. 2 iPhone4  
  4.  640x960  
  5. 3 iPhone  
  6.  320x480  


如果一个程序,既要支持iPad又要支持iPhone,那么它需要包含下面几个图片:

[plain] view plaincopy
 
  1. 1 Default-Portrait.png  
  2.  iPad专用竖向启动画面 768x1024或者768x1004  
  3. 2 Default-Landscape.png  
  4.  iPad专用横向启动画面 1024x768或者1024x748  
  5. 3 Default-PortraitUpsideDown.png  
  6.  iPad专用竖向启动画面(Home按钮在屏幕上面),可省略  
  7. 768x1024或者768x1004  
  8. 4 Default-LandscapeLeft.png  
  9.  iPad专用横向启动画面(可省略), 1024x768或者1024x748  
  10. 5 Default-LandscapeRight.png  
  11.  iPad专用横向启动画面(可省略), 1024x768或者1024x748  
  12. 6 Default.png  
  13.  iPhone默认启动图片,如果没有提供上面几个iPad专用启动图片,则在iPad上运  
  14. 行时也使用Default.png(不推荐)  
  15.  320x480或者320x460  
  16. 7 Default@2x.png  
  17.  iPhone4启动图片640x960或者640x920  


为了在iPad上使用上述的启动画面,你还需要在xxxx_info.plist中加入key(根据下拉菜单中的可选项选择):

[plain] view plaincopy
 
  1. UISupportedInterfaceOrientations  
  2. 或  
  3. Supported interface orientations  


同时,为其加入值(根据下拉菜单中的可选项选择):

[plain] view plaincopy
 
  1. 1 UIInterfaceOrientationPortrait  
  2.  或 Portrait (bottom home button)  
  3. 2 UIInterfacOrientationPortraitUpsideDown  
  4.  或 Portrait (top home button)  
  5. 3 UIInterfaceOrientationLandscapeLeft  
  6.  或 Landscape (left home button)  
  7. 4 UIInterfaceOrientationLandscapeRight  
  8.  或 Landscape (right home button)  


来源:http://www.opensoce.com/?p=1311
 
想要取消的话,直接删除default图片,之后
“Command-Option-Shift-K to clean out the build folder. Even better, quit Xcode and clean out~/Library/Developer/Xcode/DerivedData manually. Remove all its contents because there's a bug where Xcode will run an old version of your project that's in there somewhere. (Xcode 4.2 will show you the Derived Data folder: choose Window > Organizer and switch to the Projects tab. Click the right-arrow to the right of the Derived Data folder name.)
In the simulator, choose iOS Simulator > Reset Content and Settings.
Finally, for completeness, you can delete the contents of /var/folders; some caching happens there too.”

如果删除default图片之后没作用,把应用程序删除重装

原文地址:https://www.cnblogs.com/cc-Cheng/p/3354262.html