Fix bug #7244.
Fix bug #7244 by adding override the WillAnimateRotation of UIViewController.