summaryrefslogtreecommitdiff
path: root/platform/darwin/src/MGLFillStyleLayer.h
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2016-08-26 22:05:48 -0700
committerMinh Nguyễn <mxn@1ec5.org>2016-08-26 22:27:55 -0700
commitf4be8260baa1e90e24ea066d0d3b28896cd138ad (patch)
tree8aaf5902637c45e0f49c0e0f7638dbe6129a5624 /platform/darwin/src/MGLFillStyleLayer.h
parent35a1c01166f997deaa386bf30247e7cb1ed33e07 (diff)
downloadqtlocation-mapboxgl-f4be8260baa1e90e24ea066d0d3b28896cd138ad.tar.gz
[ios, macos] Specialize color properties by platform
Duplicate each color-typed property once per platform using conditional compilation macros. Let’s just hope we never have to throw CGColor into the mix.
Diffstat (limited to 'platform/darwin/src/MGLFillStyleLayer.h')
-rw-r--r--platform/darwin/src/MGLFillStyleLayer.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/platform/darwin/src/MGLFillStyleLayer.h b/platform/darwin/src/MGLFillStyleLayer.h
index bbf284833b..c03e8ecae1 100644
--- a/platform/darwin/src/MGLFillStyleLayer.h
+++ b/platform/darwin/src/MGLFillStyleLayer.h
@@ -29,14 +29,25 @@ typedef NS_ENUM(NSUInteger, MGLFillStyleLayerFillTranslateAnchor) {
*/
@property (nonatomic, null_resettable) id <MGLStyleAttributeValue> fillOpacity;
+#if TARGET_OS_IPHONE
/**
The color of the filled part of this layer. This color can be specified as rgba with an alpha component and the color's opacity will not affect the opacity of the 1pt stroke, if it is used.
- The default value of this property is `NSColor.blackColor` or `UIColor.blackColor`. Set this property to `nil` to reset it to the default value.
+ The default value of this property is `UIColor.blackColor`. Set this property to `nil` to reset it to the default value.
This property is only applied to the style if `fillPattern` is set to `nil`. Otherwise, it is ignored.
*/
@property (nonatomic, null_resettable) id <MGLStyleAttributeValue> fillColor;
+#else
+/**
+ The color of the filled part of this layer. This color can be specified as rgba with an alpha component and the color's opacity will not affect the opacity of the 1pt stroke, if it is used.
+
+ The default value of this property is `NSColor.blackColor`. Set this property to `nil` to reset it to the default value.
+
+ This property is only applied to the style if `fillPattern` is set to `nil`. Otherwise, it is ignored.
+ */
+@property (nonatomic, null_resettable) id <MGLStyleAttributeValue> fillColor;
+#endif
/**
The outline color of the fill. Matches the value of `fillColor` if unspecified.