project_files/HedgewarsMobile/Classes/OverlayViewController.m
changeset 3628 2b4d878ba565
parent 3627 f1da1d8fb56c
child 3629 86212d2b116a
equal deleted inserted replaced
3627:f1da1d8fb56c 3628:2b4d878ba565
   111     canDim = NO;
   111     canDim = NO;
   112     self.view.alpha = 0;
   112     self.view.alpha = 0;
   113     self.view.center = CGPointMake(self.view.frame.size.height/2.0, self.view.frame.size.width/2.0);
   113     self.view.center = CGPointMake(self.view.frame.size.height/2.0, self.view.frame.size.width/2.0);
   114     
   114     
   115     // set initial orientation
   115     // set initial orientation
   116     ///[self didRotate:[NSNotification notificationWithName:UIDeviceOrientationDidChangeNotification object:nil]];
       
   117     UIDeviceOrientation orientation = [[UIDevice currentDevice] orientation];
   116     UIDeviceOrientation orientation = [[UIDevice currentDevice] orientation];
   118     UIView *sdlView = [[[UIApplication sharedApplication] keyWindow] viewWithTag:12345];
   117     UIView *sdlView = [[[UIApplication sharedApplication] keyWindow] viewWithTag:12345];
   119     switch (orientation) {
   118     switch (orientation) {
   120         case UIDeviceOrientationLandscapeLeft:
   119         case UIDeviceOrientationLandscapeLeft:
   121             sdlView.transform = CGAffineTransformMakeRotation(degreesToRadian(0));
   120             sdlView.transform = CGAffineTransformMakeRotation(degreesToRadian(0));