diff options
author | Minh Nguyễn <mxn@1ec5.org> | 2018-03-30 05:43:56 -0700 |
---|---|---|
committer | Minh Nguyễn <mxn@1ec5.org> | 2018-04-02 10:42:54 -0700 |
commit | a877b6dbe8ff576f82ab9222f418da51591dd423 (patch) | |
tree | a998c9174b643e982e54d31a4bba349a6279632c /platform/darwin/src/MGLStyle.mm | |
parent | 10440640178429fc8e5c319c86e7a3e89746952e (diff) | |
download | qtlocation-mapboxgl-a877b6dbe8ff576f82ab9222f418da51591dd423.tar.gz |
[ios, macos] Renamed MGLVectorSource to MGLVectorTileSource
Diffstat (limited to 'platform/darwin/src/MGLStyle.mm')
-rw-r--r-- | platform/darwin/src/MGLStyle.mm | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/platform/darwin/src/MGLStyle.mm b/platform/darwin/src/MGLStyle.mm index 35db1b2118..66abf4391e 100644 --- a/platform/darwin/src/MGLStyle.mm +++ b/platform/darwin/src/MGLStyle.mm @@ -18,8 +18,7 @@ #import "MGLSource_Private.h" #import "MGLLight_Private.h" #import "MGLTileSource_Private.h" -#import "MGLVectorSource.h" -#import "MGLVectorSource_Private.h" +#import "MGLVectorTileSource_Private.h" #import "MGLRasterTileSource.h" #import "MGLRasterDEMSource.h" #import "MGLShapeSource.h" @@ -183,7 +182,7 @@ static_assert(6 == mbgl::util::default_styles::numOrderedStyles, // TODO: Fill in options specific to the respective source classes // https://github.com/mapbox/mapbox-gl-native/issues/6584 if (auto vectorSource = rawSource->as<mbgl::style::VectorSource>()) { - return [[MGLVectorSource alloc] initWithRawSource:vectorSource mapView:self.mapView]; + return [[MGLVectorTileSource alloc] initWithRawSource:vectorSource mapView:self.mapView]; } else if (auto geoJSONSource = rawSource->as<mbgl::style::GeoJSONSource>()) { return [[MGLShapeSource alloc] initWithRawSource:geoJSONSource mapView:self.mapView]; } else if (auto rasterSource = rawSource->as<mbgl::style::RasterSource>()) { @@ -578,15 +577,15 @@ static_assert(6 == mbgl::util::default_styles::numOrderedStyles, } if (_localizesLabels) { - NSString *preferredLanguage = [MGLVectorSource preferredMapboxStreetsLanguage]; + NSString *preferredLanguage = [MGLVectorTileSource preferredMapboxStreetsLanguage]; NSMutableDictionary *localizedKeysByKeyBySourceIdentifier = [NSMutableDictionary dictionary]; for (MGLSymbolStyleLayer *layer in self.layers) { if (![layer isKindOfClass:[MGLSymbolStyleLayer class]]) { continue; } - MGLVectorSource *source = (MGLVectorSource *)[self sourceWithIdentifier:layer.sourceIdentifier]; - if (![source isKindOfClass:[MGLVectorSource class]] || !source.mapboxStreets) { + MGLVectorTileSource *source = (MGLVectorTileSource *)[self sourceWithIdentifier:layer.sourceIdentifier]; + if (![source isKindOfClass:[MGLVectorTileSource class]] || !source.mapboxStreets) { continue; } @@ -639,9 +638,9 @@ static_assert(6 == mbgl::util::default_styles::numOrderedStyles, } } -- (NS_SET_OF(MGLVectorSource *) *)mapboxStreetsSources { - return [self.sources objectsPassingTest:^BOOL (__kindof MGLVectorSource * _Nonnull source, BOOL * _Nonnull stop) { - return [source isKindOfClass:[MGLVectorSource class]] && source.mapboxStreets; +- (NS_SET_OF(MGLVectorTileSource *) *)mapboxStreetsSources { + return [self.sources objectsPassingTest:^BOOL (__kindof MGLVectorTileSource * _Nonnull source, BOOL * _Nonnull stop) { + return [source isKindOfClass:[MGLVectorTileSource class]] && source.mapboxStreets; }]; } |