UIView height is not right on iPhone 5

后端 未结 4 1584
别那么骄傲
别那么骄傲 2020-12-28 08:34

I am migrating my apps over and on one I use a UIPickerView. In the viewDidLoad method I create the picker and set it\'s y origin to be self.view.frame.si

4条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-28 09:22

    I found the issue. My nib has to be set to "iPhone 5 full screen" (I think that's what it's called). I guess that it loads the view size from the nib and doesn't take into account autoResizeMask.

    When the view size in IB is set to "Size: None" the view is not sized right. It has to be set to "Size: Retina 4 Full Screen". Strange.

提交回复
热议问题