Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add check to make sure it's not a scroll bar, this may not be needed,…

… but can't do any harm?
  • Loading branch information...
commit 6ebd425e5e69ece2876325e5b71df3414db530fd 1 parent 991343a
@danielctull authored
Showing with 5 additions and 4 deletions.
  1. +5 −4 DTGridView/DTGridView.m
View
9 DTGridView/DTGridView.m
@@ -201,12 +201,13 @@ - (void)addCellWithInfo:(NSObject<DTGridViewCellInfoProtocol> *)info {
[self insertSubview:cell atIndex:0];
- // remove any existing view at this frame
+ // remove any existing view at this frame
for (UIView *v in self.subviews) {
- if (v.frame.origin.x == cell.frame.origin.x &&
+ if ([v isKindOfClass:[DTGridViewCell class]] &&
+ v.frame.origin.x == cell.frame.origin.x &&
v.frame.origin.y == cell.frame.origin.y &&
- v != cell)
- {
+ v != cell) {
+
[v removeFromSuperview];
break;
}
Please sign in to comment.
Something went wrong with that request. Please try again.