开发者

iphone Dev. How can I make my app compatible with iOS 3 and iPads at the same time (iOS 4.2)

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.


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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜