Adding Scott Jehl's fix for the iOS orientation bug