-
-
Save lamguy/4614666 to your computer and use it in GitHub Desktop.
UICollectionViewCell glow outline on didSelect
This file contains hidden or 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
| UICollectionViewCell* collectionViewCell = [self.collectionView cellForItemAtIndexPath:indexPath]; | |
| collectionViewCell.layer.masksToBounds = NO; | |
| collectionViewCell.layer.cornerRadius = 8; // rounded corners | |
| CGColorRef redColor = [UIColor colorWithRed:1.0 green:0.0 | |
| blue:0.0 alpha:1.0].CGColor; | |
| collectionViewCell.layer.shadowColor = redColor; | |
| collectionViewCell.layer.shadowOffset = CGSizeMake(-15, 20); | |
| collectionViewCell.layer.shadowRadius = 5; | |
| collectionViewCell.layer.shadowOpacity = 0.5; | |
| collectionViewCell.layer.shadowOffset = CGSizeMake(10,10); | |
| collectionViewCell.layer.shadowPath = [UIBezierPath bezierPathWithRect:collectionViewCell.bounds].CGPath; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment