Анимация кнопки (UIButton) по клику или без. Также можно анимировать любой другой контрол.
} completion:^(BOOL finished) {
}];
}];
}];
button.transform = CGAffineTransformScale(CGAffineTransformIdentity, 0.001, 0.001);
[self.view addSubview:button];
[UIView animateWithDuration:0.4/1.5 animations:^{
button.transform = CGAffineTransformScale(CGAffineTransformIdentity, 1.3, 1.3);
} completion:^(BOOL finished) {
[UIView animateWithDuration:0.4/2 animations:^{
button.transform = CGAffineTransformScale(CGAffineTransformIdentity, 0.8, 0.8);
} completion:^(BOOL finished) {
[UIView animateWithDuration:0.4/2 animations:^{
button.transform = CGAffineTransformScale(CGAffineTransformIdentity, 1.1, 1.1);
} completion:^(BOOL finished) {
[UIView animateWithDuration:0.4/2 animations:^{
button.transform = CGAffineTransformScale(CGAffineTransformIdentity, 1.0, 1.0);} completion:^(BOOL finished) {
button.transform = CGAffineTransformIdentity;
}];}];
}];
}];
0 коментарі:
Отправить комментарий