如何使用 FLAnimatedImage 检查动画的结尾? 我有这个代码:
@property (weak, nonatomic) IBOutlet FLAnimatedImageView *animatedImageView;
NSURL *url1 = [[NSBundle mainBundle] URLForResource:@"hand" withExtension:@"gif"];
NSData *data1 = [NSData dataWithContentsOfURL:url1];
FLAnimatedImage *animatedImage1 = [FLAnimatedImage animatedImageWithGIFData:data1];
self.animatedImageView.animatedImage = animatedImage1;
self.animatedImageView.contentMode = UIViewContentModeScaleAspectFit;
我想检测动画 gif 何时结束。我该怎么做?
最佳答案
FLAnimatedImageView
从 1.0.9 开始有一个 loopCompletionBlock
,参见 here 。添加于 https://github.com/Flipboard/FLAnimatedImage/pull/60 .
关于ios - 如何使用 FLAnimatedImage 检查动画的结束,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27578502/