mirror of
https://github.com/svga/SVGAPlayer-iOS.git
synced 2025-10-20 23:19:13 +08:00
feat: Fix demo.
This commit is contained in:
@@ -51,15 +51,15 @@ static SVGAParser *parser;
|
||||
@"https://github.com/yyued/SVGA-Samples/blob/master/rose.svga?raw=true",
|
||||
];
|
||||
[UIApplication sharedApplication].networkActivityIndicatorVisible = YES;
|
||||
// [parser parseWithURL:[NSURL URLWithString:items[arc4random() % items.count]]
|
||||
// completionBlock:^(SVGAVideoEntity * _Nullable videoItem) {
|
||||
// [UIApplication sharedApplication].networkActivityIndicatorVisible = NO;
|
||||
// if (videoItem != nil) {
|
||||
// self.aPlayer.videoItem = videoItem;
|
||||
// [self.aPlayer startAnimation];
|
||||
// }
|
||||
// } failureBlock:nil];
|
||||
|
||||
[parser parseWithURL:[NSURL URLWithString:items[arc4random() % items.count]]
|
||||
completionBlock:^(SVGAVideoEntity * _Nullable videoItem) {
|
||||
[UIApplication sharedApplication].networkActivityIndicatorVisible = NO;
|
||||
if (videoItem != nil) {
|
||||
self.aPlayer.videoItem = videoItem;
|
||||
[self.aPlayer startAnimation];
|
||||
}
|
||||
} failureBlock:nil];
|
||||
|
||||
// [parser parseWithURL:[NSURL URLWithString:@"https://github.com/svga/SVGA-Samples/raw/master_aep/BitmapColorArea1.svga"] completionBlock:^(SVGAVideoEntity * _Nullable videoItem) {
|
||||
// if (videoItem != nil) {
|
||||
// self.aPlayer.videoItem = videoItem;
|
||||
@@ -68,10 +68,10 @@ static SVGAParser *parser;
|
||||
// }
|
||||
// } failureBlock:nil];
|
||||
|
||||
[parser parseWithNamed:@"heartbeat" inBundle:nil completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
||||
self.aPlayer.videoItem = videoItem;
|
||||
[self.aPlayer startAnimation];
|
||||
} failureBlock:nil];
|
||||
// [parser parseWithNamed:@"heartbeat" inBundle:nil completionBlock:^(SVGAVideoEntity * _Nonnull videoItem) {
|
||||
// self.aPlayer.videoItem = videoItem;
|
||||
// [self.aPlayer startAnimation];
|
||||
// } failureBlock:nil];
|
||||
}
|
||||
|
||||
- (IBAction)onSliderClick:(UISlider *)sender {
|
||||
|
Reference in New Issue
Block a user