iOS orientation bug fix