-(void)animationFinished:(NSString*)animationid finished:(NSNumber*)finished
context:(void*)context
{
NSLog(@"stop");
}
}
- (IBAction)exit:(UIButton *)sender {
[UIView beginAnimations:@"exitApplication"context:nil]; //动画名称
[UIView setAnimationDuration:6];
[UIView setAnimationDelegate:self];
[UIView setAnimationTransition:UIViewAnimationTransitionCurlDown forView:self.view cache:YES];// 动画方式
//动画结束执行的操作
[UIView setAnimationDidStopSelector:@selector(animationFinished:finished:context:)];
self.view.bounds=CGRectMake(0,0, 0, 0);//动画结束
[UIView commitAnimations];
}
context:(void*)context
{
if ([animationid compare:@"exitApplication"]==0) {
// 退出应用程序
NSLog(@"stop");
}
}
- (IBAction)exit:(UIButton *)sender {
[UIView beginAnimations:@"exitApplication"context:nil]; //动画名称
[UIView setAnimationDuration:6];
[UIView setAnimationDelegate:self];
[UIView setAnimationTransition:UIViewAnimationTransitionCurlDown forView:self.view cache:YES];// 动画方式
//动画结束执行的操作
[UIView setAnimationDidStopSelector:@selector(animationFinished:finished:context:)];
self.view.bounds=CGRectMake(0,0, 0, 0);//动画结束
[UIView commitAnimations];
}