When I started my universal application, I thought the one target option would be too much work,开发者_开发技巧 so i opted for separate targets. I realized halfway through making the iPad portion of the app, that making a universal application would be easier. The issue is, I can't use Apple's option to convert my iPhone target to Universal, as there are already separate targets. Is there a workaround that allows me to upgrade my iPhone target to Universal?
Okay, I made a test app, and tried deleting the iPad target...didn't work. Then, since there were two MainWindow.xib files, I realized that something special was done to the "Resources-iPad" folder. I moved all of the files in it to another group, and deleted the "Resources-iPad" folder. This enables the "Upgrade Current Target for iPad" selection. I ran it again, but picked Universal Application, and then moved the previous inhabitants of the "Resources-iPad" back to their original home.
To recap:
- Move Files in "Resources-iPad" group to somewhere else
- Delete "Resources-iPad" group and the iPad target
- Select iPhone target and go to Project => Upgrade Current Target for iPad
- Pick Universal Application
- Move iPad Resources back into the new "Resources-iPad" folder
精彩评论