Bladeren bron

VLCPlayerDisplayController: Fix rotation resizing

With the hierarchy changes from `4f4e0033`, the view on the controller
stopped receiving callbacks for rotation(transitions). This led to
the miniplayer being broken on rotation.
Soomin Lee 6 jaren geleden
bovenliggende
commit
eb02571643
1 gewijzigde bestanden met toevoegingen van 1 en 8 verwijderingen
  1. 1 8
      Sources/VLCPlayerDisplayController.m

+ 1 - 8
Sources/VLCPlayerDisplayController.m

@@ -66,14 +66,7 @@ static NSString *const VLCPlayerDisplayControllerDisplayModeKey = @"VLCPlayerDis
 - (void)viewDidLoad
 {
     self.view = [[VLCUntouchableView alloc] initWithFrame:self.view.frame];
-}
-
-- (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id<UIViewControllerTransitionCoordinator>)coordinator
-{
-    [super viewWillTransitionToSize:size withTransitionCoordinator:coordinator];
-    [coordinator animateAlongsideTransition:^(id<UIViewControllerTransitionCoordinatorContext>  _Nonnull context) {
-        self.view.frame = CGRectMake(0, 0, size.width, size.height);
-    } completion:nil];
+    self.view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
 }
 
 #pragma mark - properties