Skip to content

Commit c474512

Browse files
author
Olivier Poitrey
committed
Fix the no image issue when no placeholder image is used with UITableViewCell default templates
1 parent 46cc079 commit c474512

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

README.md

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -197,11 +197,6 @@ the URL before to use it as a cache key:
197197
Common Problems
198198
---------------
199199

200-
### No image appear when using UITableViewCell
201-
202-
If choose to use a default cell template provided by UITableViewCell with SDWebImage, ensure you are
203-
providing a placeholder image, otherwise the cell will be initialized with no image.
204-
205200
### Using dynamic image size with UITableViewCell
206201

207202
UITableView determins the size of the image by the first image set for a cell. If your remote images

SDWebImage/UIImageView+WebCache.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,13 @@ - (void)cancelCurrentImageLoad
7070
- (void)webImageManager:(SDWebImageManager *)imageManager didProgressWithPartialImage:(UIImage *)image forURL:(NSURL *)url
7171
{
7272
self.image = image;
73+
[self setNeedsLayout];
7374
}
7475

7576
- (void)webImageManager:(SDWebImageManager *)imageManager didFinishWithImage:(UIImage *)image
7677
{
7778
self.image = image;
79+
[self setNeedsLayout];
7880
}
7981

8082
@end

0 commit comments

Comments
 (0)