Fix screen rotation issues.