Skip to content

Commit

Permalink
No need to use associated objects, just use a regular property
Browse files Browse the repository at this point in the history
For the revealing state.
  • Loading branch information
rhult committed Sep 30, 2012
1 parent c9ed44d commit 4c5f047
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions vendor/ZKRevealingTableViewCell.m
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,6 @@ @implementation ZKRevealingTableViewCell
@synthesize _lastDirection;
@synthesize _currentDirection;

#pragma mark - Public Properties

@dynamic revealing;

#pragma mark - Lifecycle

- (void)commonInit
Expand Down Expand Up @@ -133,10 +129,8 @@ - (void)setRevealing:(BOOL)revealing

- (void)_setRevealing:(BOOL)revealing
{
[self willChangeValueForKey:@"isRevealing"];
objc_setAssociatedObject(self, &BOOLRevealing, [NSNumber numberWithBool:revealing], OBJC_ASSOCIATION_RETAIN_NONATOMIC);
[self didChangeValueForKey:@"isRevealing"];

_revealing = revealing;

if (self.isRevealing && [self.delegate respondsToSelector:@selector(cellDidReveal:)])
[self.delegate cellDidReveal:self];
}
Expand Down

0 comments on commit 4c5f047

Please sign in to comment.