Fix error with screen rotate