I have developed an application for iPad and now I want to adapt it to iPhone, then I realized that I have two options: I can create an iPhone Environment or create a skin for iPhone.
The point is that if I create iPhone and iPad environments and I upload both .ipa to the application center, the user will find two applications with the same name available for download. I have not found the way to avoid this in Application Center. I can only add the platform in the description.
What is the best option? What is the difference between iPad and iPhone Environments?
EDIT: I'm not being able to create a skin in the iPad Environment, the getSkinName function is not executed.
The Xcode projects generated by Worklight Studio for the iPhone and iPad environments are both created with the Universal application setting. Their codebase (Worklight-framework related) is mostly the same...
You can change the generated project from being Universal to being device-specific. This is a setting that you can tweak in Xcode.
bundleId
s for each...After doing so, the App Center management console will be able to distinguish between the iPad and iPhone app. You can then simply edit the upload entry and give it a different label. This label change only affects what you see in the management console, not the app name itself, so all is good.
I have also confirmed that Worklight Skins do work in the iPad environment.
Added a new appName.js (for Worklight 5.0.6/6.0, or main.js for Worklight 6.1) file in the
ipad.skin\js
folder with:Edited
ipad\js\skinLoader.js
file to use:Built and deployed
Result: the app opened in the iOS Simulator with an alert stating "test". Ergo, works...
Please make sure you have followed these steps.