diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2017-04-11 16:28:19 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2017-04-13 10:33:18 -0700 |
commit | e5c6d2838db146bdde68ba365712deb32c61ad67 (patch) | |
tree | dd67748d5907eb480d4c6f86235f13ea636ca14f /platform/darwin/src/MGLStyle.mm | |
parent | 7b041b123cb067d247a727bb3a4563bb2fc575eb (diff) | |
download | qtlocation-mapboxgl-e5c6d2838db146bdde68ba365712deb32c61ad67.tar.gz |
[darwin] Make -[MGLForegroundStyleLayer sourceIdentifier] abstract
It's already overridden by concrete subclasses, and by making it abstract we enable the removal of the private MGLForegroundStyleLayer category.
Diffstat (limited to 'platform/darwin/src/MGLStyle.mm')
-rw-r--r-- | platform/darwin/src/MGLStyle.mm | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/platform/darwin/src/MGLStyle.mm b/platform/darwin/src/MGLStyle.mm index b01d9aa513..0912993825 100644 --- a/platform/darwin/src/MGLStyle.mm +++ b/platform/darwin/src/MGLStyle.mm @@ -12,7 +12,6 @@ #import "MGLStyle_Private.h" #import "MGLStyleLayer_Private.h" -#import "MGLForegroundStyleLayer_Private.h" #import "MGLSource_Private.h" #import "NSDate+MGLAdditions.h" @@ -332,20 +331,15 @@ static NSURL *MGLStyleURL_emerald; } if (auto fillLayer = rawLayer->as<mbgl::style::FillLayer>()) { - MGLSource *source = [self sourceWithIdentifier:@(fillLayer->getSourceID().c_str())]; - return [[MGLFillStyleLayer alloc] initWithRawLayer:fillLayer source:source]; + return [[MGLFillStyleLayer alloc] initWithRawLayer:fillLayer]; } else if (auto lineLayer = rawLayer->as<mbgl::style::LineLayer>()) { - MGLSource *source = [self sourceWithIdentifier:@(lineLayer->getSourceID().c_str())]; - return [[MGLLineStyleLayer alloc] initWithRawLayer:lineLayer source:source]; + return [[MGLLineStyleLayer alloc] initWithRawLayer:lineLayer]; } else if (auto symbolLayer = rawLayer->as<mbgl::style::SymbolLayer>()) { - MGLSource *source = [self sourceWithIdentifier:@(symbolLayer->getSourceID().c_str())]; - return [[MGLSymbolStyleLayer alloc] initWithRawLayer:symbolLayer source:source]; + return [[MGLSymbolStyleLayer alloc] initWithRawLayer:symbolLayer]; } else if (auto rasterLayer = rawLayer->as<mbgl::style::RasterLayer>()) { - MGLSource *source = [self sourceWithIdentifier:@(rasterLayer->getSourceID().c_str())]; - return [[MGLRasterStyleLayer alloc] initWithRawLayer:rasterLayer source:source]; + return [[MGLRasterStyleLayer alloc] initWithRawLayer:rasterLayer]; } else if (auto circleLayer = rawLayer->as<mbgl::style::CircleLayer>()) { - MGLSource *source = [self sourceWithIdentifier:@(circleLayer->getSourceID().c_str())]; - return [[MGLCircleStyleLayer alloc] initWithRawLayer:circleLayer source:source]; + return [[MGLCircleStyleLayer alloc] initWithRawLayer:circleLayer]; } else if (auto backgroundLayer = rawLayer->as<mbgl::style::BackgroundLayer>()) { return [[MGLBackgroundStyleLayer alloc] initWithRawLayer:backgroundLayer]; } else if (auto customLayer = rawLayer->as<mbgl::style::CustomLayer>()) { |