iOS9: UIDatePicker with datePickerMode of UIDatePickerModeTime only shows Hours, and no Minutes

后端 未结 6 1759
暗喜
暗喜 2021-02-14 07:13

I\'m using Xcode beta 7 with the iOS9 simulator. Using a UIDatePicker with a datePickerMode of UIDatePickerModeTime only shows Hours, and not minutes.

See screenshot:

6条回答
  •  清酒与你
    2021-02-14 07:53

    I have same issue when running my app in iOS 9, my app using UIDatePicker in .xib file. I resolved this problem by add it in code behind:

    UIDatePicker* picker = [[UIDatePicker alloc] initWithFrame:CGRectMake(0, 44, 320, 162)];
    [self.view addSubview:picker];
    

    I think, this's problem with new font San Francisco (the font is big than Helvetica) and .xib file. Hope this help. Thank!

提交回复
热议问题