summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2016-08-16 02:10:56 -0700
committerGitHub <noreply@github.com>2016-08-16 02:10:56 -0700
commitdcd9e1016cd20f107c4e34be62c631a1f4189af1 (patch)
tree2f313708a6b049742d15dde5af67fcde4ab038af /platform
parent18176605f65ce90c973e0b61a1a2b563471b0ba5 (diff)
downloadqtlocation-mapboxgl-dcd9e1016cd20f107c4e34be62c631a1f4189af1.tar.gz
[ios, macos] Removed MGLSource.sourceType (#6028)
Fixes #6027.
Diffstat (limited to 'platform')
-rw-r--r--platform/darwin/src/MGLGeoJSONSource.mm5
-rw-r--r--platform/darwin/src/MGLRasterSource.mm4
-rw-r--r--platform/darwin/src/MGLSource.h3
-rw-r--r--platform/darwin/src/MGLSource.mm3
4 files changed, 4 insertions, 11 deletions
diff --git a/platform/darwin/src/MGLGeoJSONSource.mm b/platform/darwin/src/MGLGeoJSONSource.mm
index 92c5b87e89..957f632855 100644
--- a/platform/darwin/src/MGLGeoJSONSource.mm
+++ b/platform/darwin/src/MGLGeoJSONSource.mm
@@ -12,12 +12,9 @@
@implementation MGLGeoJSONSource
-static NSString *MGLGeoJSONSourceType = @"geojson";
-static NSString *MGLGeoJSONDataKey = @"data";
-
- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier URL:(NSURL *)url
{
- if (self = [super initWithSourceIdentifier:sourceIdentifier sourceType:MGLGeoJSONSourceType]) {
+ if (self = [super initWithSourceIdentifier:sourceIdentifier]) {
_URL = url;
if (url.isFileURL) {
_data = [[NSString alloc] initWithContentsOfURL:url encoding:NSUTF8StringEncoding error:NULL];
diff --git a/platform/darwin/src/MGLRasterSource.mm b/platform/darwin/src/MGLRasterSource.mm
index 5f3881b285..b3e474f36f 100644
--- a/platform/darwin/src/MGLRasterSource.mm
+++ b/platform/darwin/src/MGLRasterSource.mm
@@ -6,10 +6,8 @@
@implementation MGLRasterSource
-static NSString *MGLRasterSourceType = @"raster";
-
- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier URL:(NSURL *)url tileSize:(CGFloat)tileSize {
- if (self = [super initWithSourceIdentifier:sourceIdentifier sourceType:MGLRasterSourceType]) {
+ if (self = [super initWithSourceIdentifier:sourceIdentifier]) {
_URL = url;
_tileSize = tileSize;
}
diff --git a/platform/darwin/src/MGLSource.h b/platform/darwin/src/MGLSource.h
index b08a09ec4d..4d0fd49ea2 100644
--- a/platform/darwin/src/MGLSource.h
+++ b/platform/darwin/src/MGLSource.h
@@ -4,8 +4,7 @@
@interface MGLSource : NSObject
@property (nonatomic, copy) NSString *sourceIdentifier;
-@property (nonatomic, copy) NSString *sourceType;
-- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier sourceType:(NSString *)sourceType;
+- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier;
@end
diff --git a/platform/darwin/src/MGLSource.mm b/platform/darwin/src/MGLSource.mm
index c80fbe914c..2b73074b09 100644
--- a/platform/darwin/src/MGLSource.mm
+++ b/platform/darwin/src/MGLSource.mm
@@ -4,10 +4,9 @@
@implementation MGLSource
-- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier sourceType:(NSString *)sourceType {
+- (instancetype)initWithSourceIdentifier:(NSString *)sourceIdentifier {
if (self = [super init]) {
_sourceIdentifier = sourceIdentifier;
- _sourceType = sourceType;
}
return self;
}