//动画icon
_iconView = [[UIImageView alloc]init];
[self.contentView addSubview:_iconView];
[_iconView mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.equalTo(_imageView).offset(8);
make.height.mas_equalTo(10);
make.width.mas_equalTo(12);
make.bottom.equalTo(_imageView).offset(-5);
}];
NSArray* iconArray = @[@"live_icon_1",@"live_icon_2",@"live_icon_3",@"live_icon_4"];
NSMutableArray* imageArray = [NSMutableArray array];
for (NSString* temp in iconArray) {
UIImage* img =[UIImage imageNamed:temp];
[imageArray addObject:img];
}
_iconView.animationImages = imageArray;
_iconView.animationRepeatCount = 0;
_iconView.animationDuration = 1;
[_iconView startAnimating];
11540522171_.pic.jpg
网友评论