Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><a href="http://redth.info/get-your-monotouch-apps-ready-for-iphone-5-ios-6-today/" rel="nofollow">Here's</a> a link that will actually help you. Save the launch image, iOS doesn't automatically pick the right image if you put in a "-568h@2x.png" at the end of the file name. There are a couple of helper methods mentioned in the <a href="http://redth.info/get-your-monotouch-apps-ready-for-iphone-5-ios-6-today/" rel="nofollow">above link</a> that will make your job easy.</p> <p>I have adopted the code in the links I mentioned above and here's the helper function for Obj-C:</p> <pre><code>-(BOOL) IsTall { return ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) &amp;&amp; ([[UIScreen mainScreen] bounds].size.height * [[UIScreen mainScreen] scale] &gt;= 1136); } </code></pre> <p>A little category-writing would help too.</p> <pre><code>@interface NSString (Special) -(NSString*)correctImageNameForiPhone5 @end @implementation NSString (Special) -(NSString*)correctImageNameForiPhone5 { if([self isTall]) return -imageNameAppendedWith_-568h@2x.png_-; //Do the correct NSString magic here else return -originalImageName-; } @end </code></pre> <p>Finally, when you are accessing the UIImage object:</p> <pre><code>NSString *filename = @"backgroundImage.png"; UIImage *img = [UIImage imageNamed:[filename correctImageNameForiPhone5]]; </code></pre> <p>The assumption here is that you would have all your iPhone5-specific image file names ending with "-568h@2x". This code sample is definitely not gonna work if you just drop it into your project, but you get the idea. It needs some NSString fixes.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload