Search code examples
ios5ios6iphone-5autolayoutiphone-4

Should I have two nibs to give support to the screens for iPhone 5 / iPhone 4?


I started to work in an App that needs to be optimized for iPhone 5 and requires iOS 5.x or later.

But the scenario where the user has and iPhone 4 with iOS 5.x is possible. But the Autolayout will be a problem on those cases...

So, I could use Autolayout for iPhone 5,but the users with iOS 5.x(iPhone 4 or below) will have problems, so in order to avoid that, should I have two nib's one for give support to the iPhone 5 screen and another iPhone 4? (And that sounds very ugly to me).

Having something like this...

if(IPHONE5){
//Load iPhone 5 nib with AutoLayout or without it
}else{
//Load iPhone 4 or below 
}

In any case, is there a better option to give support to both screens but with different iOS versions? suggestion on this?

Since now thanks


Solution

  • This is something that I had been wondering about myself. However, I stumbled upon a webpage: "Drop iOS 5: Only support iOS 6" that explains that such scenarios if possible, should be avoided.

    Doing development for older OS's might seem reasonable, however...

    • the rate in which people update their phones is extreme fast (unlike Android)
    • the development time increases
    • development costs increase
    • maintaining code more complex
    • release dates become later

    as a result:

    • more people have upgraded to the newer OS
    • your 'older share' has become less relevant
    • your 'lost sales' is even smaller
    • your 'return of investment' because of increased cost has extended

    My advise: drop iOS-5