1

I have this code to move the view when keyboard appears:

const int movementDistance = -160; // tweak as needed
const float movementDuration = 0.3f; // tweak as needed

int movement = (up ? movementDistance : -movementDistance);

[UIView beginAnimations: @"animateTextField" context: nil];
[UIView setAnimationBeginsFromCurrentState: YES];
[UIView setAnimationDuration: movementDuration];
self.view.frame = CGRectOffset(self.view.frame, 0, movement);
[UIView commitAnimations];

This code works for iOS7 & iOS8 but with iOS9 doesn't move all items in the view, only a few of them.

(the constrains are the same)

Someone with the same problem?

Thanks for your time!

Kotik_o
  • 295
  • 6
  • 19
  • I have a similar problem. No solution yet. Similar to http://stackoverflow.com/questions/32632207/cant-move-keyboard-view-ios9-swift and https://github.com/PureLayout/PureLayout/issues/82#issuecomment-141334708 – Tristan.Liu Sep 18 '15 at 04:40

0 Answers0