Reputation: 6465
I have to create a new app and I am using X Code 4.5 and iOS 6 but when I am creating a UIViewController class with XIB, it is giving me the view of iPhone 5. I understand that but I want to create UI for iPhone 4 as well. How can I add the XIB for iPhone 4?
Upvotes: 0
Views: 304
Reputation: 3296
I dont think so that the XIB file can be changed for iPhone4 and iPhone5. I think you just need to set the UIComponents
in the XIB file, taking into account the iPhone4 screen size and set the frame of UIComponents
inside the frame i.e 320*480
for iPhone4. Leave the rest of space empty. It will work for iPhone 4. And if you want the application to run for iPhone5 also then just set the property Use AutoLayout
on. Dats it..
Upvotes: 2