Browse Source

improved compatibility

ibireme 9 năm trước cách đây
mục cha
commit
46c7fb5814
1 tập tin đã thay đổi với 7 bổ sung0 xóa
  1. 7 0
      YYWebImage/Image/YYAnimatedImageView.m

+ 7 - 0
YYWebImage/Image/YYAnimatedImageView.m

@@ -197,6 +197,13 @@ typedef NS_ENUM(NSUInteger, YYAnimagedImageType) {
     return self;
 }
 
+- (instancetype)initWithFrame:(CGRect)frame {
+    self = [super initWithFrame:frame];
+    _runloopMode = NSRunLoopCommonModes;
+    _autoPlayAnimatedImage = YES;
+    return self;
+}
+
 - (instancetype)initWithImage:(UIImage *)image {
     self = [super init];
     _runloopMode = NSRunLoopCommonModes;