YBImageBrowser图片不显示

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#import "YYAnimatedImageView+Extension.h"

@implementation YYAnimatedImageView (Extension)

+(void)load
{
Method method1 = class_getInstanceMethod(self, @selector(displayLayer:));
Method method2 = class_getInstanceMethod(self, @selector(dx_displayLayer:));
method_exchangeImplementations(method1, method2);
}

-(void)dx_displayLayer:(CALayer *)layer {

if ([UIImageView instancesRespondToSelector:@selector(displayLayer:)]) {
[super displayLayer:layer];
}
}
@end