Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // GradientView.m
- // StravaExplorer
- //
- // Created by Jeff Remer on 9/16/11.
- // Copyright 2011 Strava. All rights reserved.
- //
- #import "GradientView.h"
- #import <QuartzCore/QuartzCore.h>
- @implementation GradientView
- + (Class)layerClass {
- return [CAGradientLayer class];
- }
- - (void)setGradientColors:(NSArray *)colors {
- SEL setColorsSel = @selector(setColors:);
- if ([self.layer respondsToSelector:setColorsSel]) {
- [self.layer performSelector:setColorsSel withObject:colors];
- }
- }
- @end
Add Comment
Please, Sign In to add comment