fixes the animation when rotating the iPad