0

I've faced up with a weird problem with my app (seems like it's a reason why I can't pass Apple's review), prerequisites:

  • UIViewController with 2 UITextfield,
  • No constraints (it's same with constraints),
  • iPad 5 generation simulator (iPhone sim is ok!),
  • hardware keyboard (Simulator ~> Hardware ~> Keyboard ~> Connect Hardware Keyboard.

How to reproduce:

  1. launch the app on the simulator,
  2. tap on the first textfield,
  3. press tab on your Mac's keyboard.

Result:

NSAutoresizingMaskLayoutConstraint:0x60000048b9f0 h=--& v=--& UIKeyboardAssistantBar:0x7ff04dc13ae0.height == 0...

Video: https://www.dropbox.com/s/2ag1dw2llnm9sxf/screencast%202018-03-16%2008-59-32.mp4?dl=0

Output: https://www.dropbox.com/s/oeidkmvzhe6n46s/screencast%202018-03-16%2008-59-32.txt?dl=0

Test project: https://www.dropbox.com/s/czqy8zhh8pbr8zo/TestVirtualKeyboard.zip?dl=0

PS: I've found some related issues (unresolved): https://forums.developer.apple.com/message/209609#209609 https://forums.developer.apple.com/message/157784#157784

Maxim Firsoff
  • 2,038
  • 22
  • 28

1 Answers1

0

The solution is here: _UIButtonBarStackView: breaking constraint when becomeFirstResponder sent

For each UItextField:

inputAssistantItem.leadingBarButtonGroups = []
inputAssistantItem.trailingBarButtonGroups = []
Maxim Firsoff
  • 2,038
  • 22
  • 28