0

I've been looking around for a way to make my application compatible with iPhones-iOS3 and at the same time make it compatible with iphones and iPads that have iOS 4.2

I have seen some apps on the app store that claim to be compatible with iphones iOS3 and above, and with iPads.

Any idea on how they do that? How do they test against the different versions and how do they compile the final version that gets uploaded on the app store.

manospro
  • 799
  • 1
  • 6
  • 16

1 Answers1

0

To make your app load in both iPad and iPhone, just make sure you have 2 different xibs to cater for each device, at application launch, check the device whether it's an iPad or iPhone and load the xib file accordingly.

iOS3 and multitasking unsupported devices will call applicationDidTerminate method when home button is pressed. iOS4 onwards, just make sure applicationDidEnterBackground method is implemented to support multitasking. You could also uncheck in the Info.plist file that your app does not support multitasking (not recommended by Apple), iOS will call applicationDidTerminate instead and the app will still be usable in both iOS3 & iOS4.

Cheers.

Seyther
  • 652
  • 4
  • 6
  • That means of course that I would have to compile under 3 SDK right? – manospro Jan 26 '11 at 09:10
  • You don't have to. Just make sure both applicationDidTerminate and applicationDidEnterBackground methods are implemented and working in the latest iOS build (iOS4.2 or iOS4.3 beta), it would be fine for iOS3 and iOS4 devices. Cheers. – Seyther Jan 26 '11 at 09:22
  • Hang on a min. I have the latest released SDK 4.2 on my Xcode. How am I supposed to test on OS3? Im aware of the applicationDidTerminate and applicationDidEnterBackground, but I was under the impression that the app is compatible from the SDK you compile under, onwards. If this is not the case PLEASE clarify because my app is currently available on OS4.2 and later :-( – manospro Jan 26 '11 at 09:51
  • The only main difference between iOS3 & iOS4 is just the backgrounding issue. Implement both the methods, build in iOS4.2 SDK, it would work fine even if is iOS3 device using that app, just that iOS3 calls appDidTerminate instead of appDidEnterBackground. So in any case it shouldn't matter. – Seyther Jan 26 '11 at 10:59
  • I understand the main diffs between the two iOS. However, my argument is that I have implemented both methods (mainly because 3G phones don't offer multi-tasking even if they have iOS 4.2). The problem I have however is that when I submit my app on the App Store it becomes compatible for "iOS 4.2 or later". I assumed it was because I used the 4.2 SDK to compile the app. For example when the SDK 4.3 gets released, if I compile my app on that SDK and submit my app, the App Store will automatically detect that and set my app compatible for iOS 4.3 or later. What am I doing wrong? – manospro Jan 26 '11 at 11:08
  • if the multitasking is not supported in the device, appDidTerminate will be called. You are doing nothing wrong, your app should always be compatible with the latest iOS build and that is what you need to be concerned with. I think there is also a deployment target to set to the earliest version you want to be able to run with, in the project. You could reference this article and see if it helps http://stackoverflow.com/questions/3027120/how-to-make-iphone-app-compatible-with-multiple-sdk-firmware-versions – Seyther Jan 26 '11 at 11:35
  • The iOS Deployment Target...! Thanks mate you were great help. Thanks a milion – manospro Jan 26 '11 at 11:52