How to make xib compatible with both iphone 5 and iphone 4 devices

前端 未结 14 1804
执念已碎
执念已碎 2020-11-28 20:39

I am trying to layout my xib so that layout fits in both iphone 5 (4 inches retina) and 3.5 devices.

Because I have to support IOS-5 I cannot use autolayout. I have

14条回答
  •  失恋的感觉
    2020-11-28 21:20

    Try adding this to all your controllers which need to support iPhone 5:

    - (void) loadView
    {
        [super loadView];
        self.view.frame = [UIScreen mainScreen].bounds;
    }
    

提交回复
热议问题