简体   繁体   中英

Titanium - How to make an iphone-only app run nicely in iPad's compatibility mode?

so today my app was rejected in the app store because of this:

Reasons

2.10: iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution

Considerations:
- This app is an iphone-only, meaning that is the only target that I chose in the tiapp.xml.
- This app was already accepted once in the appstore, this is an update.
- In my code sometimes I use px for imagens and sometimes DP, but I've tried switching all to DP in this screen and had even worse results.

As far as I can see, there are no errors associated with it (that means the app does NOT crash when you run it in iPad simulator) therefore I'm assuming they rejected it because of a layout problem.
Since this is an iphone-only app, iPad should run the app in compatibility mode, meaning that it might scale it up, but respecting the original sizes.
This is a pic of the app running in a retina simulator (with no problems):

在此处输入图片说明

And here's a picture of the app running in a retina iPad simulator (though the result is the same in a non-retina):

在此处输入图片说明

As you can see, everything's huge and I have no clue why. I'm running ios7.1, Titanium SDK version 3.3.0.GA and it's a alloy app.
Any help is very much appreciated, thanks.

The point 2.10 reference any resources of app. So, if you have not resources, for example, screenshot before load application, your app will be reject. The iPhone apps should have iPad resources, but iPad apps may be independent.

My problem was not the iPad resources or splash screens. Actually, I was using PIXELS instead of DP in many places in my application. This was not a problem for none of the iPhone versions, but was a problem when iPad tried to run the iPhone-only app in compatibility mode. In any case, now there's also the iPhone 6 with different resolutions so one should never use pixels.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM