diff --git a/MAConfirmButton/MAConfirmButton.m b/MAConfirmButton/MAConfirmButton.m index b0cfd7e..982573e 100644 --- a/MAConfirmButton/MAConfirmButton.m +++ b/MAConfirmButton/MAConfirmButton.m @@ -272,7 +272,7 @@ - (void)setAnchor:(CGPoint)anchor{ } - (void)setTintColor:(UIColor *)color{ - self.tint = [UIColor colorWithHue:color.hue saturation:color.saturation+0.15 brightness:color.brightness alpha:1]; + self.tint = [UIColor newColorWithHue:color.hue saturation:color.saturation+0.15 brightness:color.brightness alpha:1]; colorLayer.backgroundColor = tint.CGColor; [self setNeedsDisplay]; } diff --git a/MAConfirmButton/UIColor-Expanded.h b/MAConfirmButton/UIColor-Expanded.h index da06bfe..40d6da1 100755 --- a/MAConfirmButton/UIColor-Expanded.h +++ b/MAConfirmButton/UIColor-Expanded.h @@ -78,7 +78,7 @@ + (NSDictionary *)namedCrayons; // Build a color with the given HSB values -+ (UIColor *)colorWithHue:(CGFloat)hue saturation:(CGFloat)saturation brightness:(CGFloat)brightness alpha:(CGFloat)alpha; ++ (UIColor *)newColorWithHue:(CGFloat)hue saturation:(CGFloat)saturation brightness:(CGFloat)brightness alpha:(CGFloat)alpha; // Low level conversions between RGB and HSL spaces + (void)hue:(CGFloat)h saturation:(CGFloat)s brightness:(CGFloat)v toRed:(CGFloat *)r green:(CGFloat *)g blue:(CGFloat *)b; diff --git a/MAConfirmButton/UIColor-Expanded.m b/MAConfirmButton/UIColor-Expanded.m index d117618..5badb95 100755 --- a/MAConfirmButton/UIColor-Expanded.m +++ b/MAConfirmButton/UIColor-Expanded.m @@ -349,7 +349,7 @@ - (UIColor *)complementaryColor { if (h > 360.f) h -= 360.0f; // Create a color in RGB - return [UIColor colorWithHue:h saturation:s brightness:v alpha:a]; + return [UIColor newColorWithHue:h saturation:s brightness:v alpha:a]; } // Pick two colors more colors such that all three are equidistant on the color wheel @@ -540,7 +540,7 @@ + (NSDictionary *)namedCrayons { return crayolaNameCache; } -+ (UIColor *)colorWithHue:(CGFloat)hue saturation:(CGFloat)saturation brightness:(CGFloat)brightness alpha:(CGFloat)alpha { ++ (UIColor *)newColorWithHue:(CGFloat)hue saturation:(CGFloat)saturation brightness:(CGFloat)brightness alpha:(CGFloat)alpha { // Convert hsb to rgb CGFloat r,g,b; [self hue:hue saturation:saturation brightness:brightness toRed:&r green:&g blue:&b];