我正在使用此代码为我的视图制作波纹动画
transition = [CATransition animation];
transition.delegate = self;
transition.duration = 3;
transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut];
NSString *types[4] = {@"cube", @"rippleEffect", @"cube", @"alignedCube"};
NSString *subtypes[4] = {kCATransitionFromLeft, kCATransitionFromRight, kCATransitionFromTop, kCATransitionFromRight};
transition.type = types[1];
transition.subtype = subtypes[1];
现在我想通过点击停止动画,然后我想从我停止的视图开始......
我试过了
[view.layer removeAllAnimations];
但我发现以下事情不起作用..任何建议???