Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #2 from berzniz/master

Unused cells show up unexpectedly
  • Loading branch information...
commit 7b2d2f306a2bcddf1f9e565ecf6ffabb9f82addd 2 parents 0cfda25 + 23eecfd
@messi messi authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  NGVaryingGridView/NGVaryingGridView/NGVaryingGridView.m
View
1  NGVaryingGridView/NGVaryingGridView/NGVaryingGridView.m
@@ -197,6 +197,7 @@ - (void)loadCellsInRect:(CGRect)rect {
// Move unused Cells to reusableCells
NSMutableDictionary *unusedCells = [NSMutableDictionary dictionaryWithDictionary:self.gridCells];
[unusedCells removeObjectsForKeys:usedCells.allKeys];
+ [unusedCells.allValues makeObjectsPerformSelector:@selector(removeFromSuperview)];
[self.gridCells removeObjectsForKeys:unusedCells.allKeys];
[self.reuseableCells addObjectsFromArray:unusedCells.allValues];
Please sign in to comment.
Something went wrong with that request. Please try again.