Created
March 6, 2012 04:00
-
-
Save XMLSDK/1983329 to your computer and use it in GitHub Desktop.
UIColor+CFAdditions Category to handle UIColor.CGColor in ARC
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
#import <UIKit/UIKit.h> | |
@interface UIColor (CFAdditions) | |
- (CGColorRef)CGColorRetained; | |
@end |
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
#import "UIColor+CFAdditions.h" | |
@implementation UIColor (CFAdditions) | |
- (CGColorRef)CGColorRetained | |
{ | |
return CGColorRetain(self.CGColor); | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment