Passing in CGPoints instead of NSArrays for start/end.
This commit is contained in:
parent
6dcee98b6d
commit
7c6695ea1d
|
@ -24,14 +24,14 @@
|
||||||
self.gradientLayer.colors = colors;
|
self.gradientLayer.colors = colors;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)setStart:(NSArray *)start
|
- (void)setStart:(CGPoint)start
|
||||||
{
|
{
|
||||||
self.gradientLayer.startPoint = [RCTConvert CGPoint:start];
|
self.gradientLayer.startPoint = start;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)setEnd:(NSArray *)end
|
- (void)setEnd:(CGPoint)end
|
||||||
{
|
{
|
||||||
self.gradientLayer.endPoint = [RCTConvert CGPoint:end];
|
self.gradientLayer.endPoint = end;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)setLocations:(NSArray *)locations
|
- (void)setLocations:(NSArray *)locations
|
||||||
|
|
|
@ -19,8 +19,8 @@ RCT_EXPORT_MODULE();
|
||||||
}
|
}
|
||||||
|
|
||||||
RCT_EXPORT_VIEW_PROPERTY(colors, NSArray);
|
RCT_EXPORT_VIEW_PROPERTY(colors, NSArray);
|
||||||
RCT_EXPORT_VIEW_PROPERTY(start, NSArray);
|
RCT_EXPORT_VIEW_PROPERTY(start, CGPoint);
|
||||||
RCT_EXPORT_VIEW_PROPERTY(end, NSArray);
|
RCT_EXPORT_VIEW_PROPERTY(end, CGPoint);
|
||||||
RCT_EXPORT_VIEW_PROPERTY(locations, NSArray);
|
RCT_EXPORT_VIEW_PROPERTY(locations, NSArray);
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
Loading…
Reference in New Issue