Created
July 11, 2016 14:39
-
-
Save IvanovDeveloper/b46f745ca2e0993dd7a5701a9cb64609 to your computer and use it in GitHub Desktop.
Как определить момент до поворота экрана и после поворота экрана
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id <UIViewControllerTransitionCoordinator>)coordinator | |
| { | |
| [super viewWillTransitionToSize:size withTransitionCoordinator:coordinator]; | |
| [coordinator animateAlongsideTransition:^(id<UIViewControllerTransitionCoordinatorContext> context) { | |
| // Stuff you used to do in willRotateToInterfaceOrientation would go here. | |
| // If you don't need anything special, you can set this block to nil. | |
| } completion:^(id<UIViewControllerTransitionCoordinatorContext> context) { | |
| // Stuff you used to do in didRotateFromInterfaceOrientation would go here. | |
| // If not needed, set to nil. | |
| }]; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment