summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2018-11-15 23:40:36 -0800
committerMinh Nguyễn <mxn@1ec5.org>2018-11-15 23:40:36 -0800
commit0addd511d5fa503dc67d0773893c66c000e3ec98 (patch)
tree16be7dfafe6ae704631b5ed28ed5d2c337b41b08
parent44a6530e650ecbfc7172d41903df31858f15046b (diff)
downloadqtlocation-mapboxgl-upstream/1ec5-macos-srgb-13386.tar.gz
[macos] Simplified testupstream/1ec5-macos-srgb-13386
-rw-r--r--platform/darwin/test/MGLTileSetTests.mm15
1 files changed, 5 insertions, 10 deletions
diff --git a/platform/darwin/test/MGLTileSetTests.mm b/platform/darwin/test/MGLTileSetTests.mm
index 848a42bf33..9a09a2bd09 100644
--- a/platform/darwin/test/MGLTileSetTests.mm
+++ b/platform/darwin/test/MGLTileSetTests.mm
@@ -69,16 +69,11 @@
#if TARGET_OS_IPHONE
UIColor *redColor = [UIColor redColor];
#else
- NSColor *redColor;
- if ([NSColor redColor].colorSpaceName == NSCalibratedRGBColorSpace) {
- // CSS uses the sRGB color space.
- redColor = [NSColor colorWithSRGBRed:1 green:0 blue:0 alpha:1];
- } else {
- // AppKit incorrectly uses calibrated RGB when exporting HTML, so input
- // calibrated RGB to ensure round-tripping.
- // <rdar://problem/46115233> <http://www.openradar.me/46115233>
- redColor = [NSColor colorWithCalibratedRed:1 green:0 blue:0 alpha:1];
- }
+ // CSS uses the sRGB color space.
+ // AppKit incorrectly uses calibrated RGB when exporting HTML, so input
+ // calibrated RGB to ensure round-tripping.
+ // <rdar://problem/46115233> <http://www.openradar.me/46115233>
+ NSColor *redColor = [NSColor colorWithCalibratedRed:1 green:0 blue:0 alpha:1];
#endif
NSAttributedString *gl = [[NSAttributedString alloc] initWithString:@"GL" attributes:@{
NSBackgroundColorAttributeName: redColor,