Created
February 10, 2014 13:08
-
-
Save muukii/8915623 to your computer and use it in GitHub Desktop.
Drawrect Animation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)setHighlighted:(BOOL)highlighted animated:(BOOL)animated{ | |
[super setHighlighted:highlighted]; | |
[self setNeedsDisplay]; | |
if (animated) { | |
[UIView transitionWithView:self duration:0.1 | |
options:UIViewAnimationOptionTransitionCrossDissolve | |
animations:^{ | |
[self.layer displayIfNeeded]; | |
} completion:nil]; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment