I have 3000 Images in my phone. When I running MWPhotoBrowser in my phone. And if I swipe too fast. It's going to crash.
Asked
Active
Viewed 69 times
1 Answers
0
At MWGridViewController, the code in cellForRow. The original method to request images it by using notification. And now I change it by using block. It works good for me.
//my code
[photo requestImageForAsset:photo.asset size:CGSizeMake(cell.width * 2, cell.height * 2) resizeMode:PHImageRequestOptionsResizeModeFast completion:^(UIImage *image, NSDictionary *info) {
if(image){
photo.loadingInProgress = NO;
cell.imageView.image = image;
[cell hideLoadingIndicator];
cell.selectedButton.hidden = !_selectionMode;
[cell hideImageFailure];
}
}];
//original code
UIImage *img = [_browser imageForPhoto:photo];
if (img) {
[cell displayImage];
} else {
[photo loadUnderlyingImageAndNotify];
}

Alan Luo
- 159
- 1
- 13
-
where is "requestImageForAsset" is defined? – ArgaPK Feb 22 '22 at 09:59