I have an if statement in my app to detect whether or not to move the view up when the keyboard appears. I have a separate one of 3.5/4, 4.7 and 5.5 inch screens.
The ones for the 3.5/4 and 5.5 inch screens work great, however for some reason, the one for the 4.7 inch screen isn't functioning.
This is my code:
if keyboardActive == false && height == 667 && self.entryView.center.y == 333.5 {
If I remove self.entryView.center.y == 333.5
then it works, so that's the problem. I've tried rounding up to 334 and down to 333 but that didn't help.
Does anyone know why the centre y value is not 333.5?