Используйте следующий код для увеличения.
// Fade In
- (void)fadeInModalView {
[self.view addSubview:modalView];
modalView.alpha = 0;
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDuration:0.3];
modalView.alpha = 0.9;
[UIView commitAnimations];
}
Исчезать.
// Fade Out
- (void)fadeOutModalView {
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDuration:0.3];
[UIView setAnimationDelegate:self];
[UIView setAnimationDidStopSelector:@selector(removeModalView)];
modalView.alpha = 0.0;
[UIView commitAnimations];
}
Чтобы удалить modalView после того, как он исчез.
// Remove modalView after it faded out
- (void)removeModalView {
[modalView removeFromSuperview];
}