diff options
author | Minh Nguyễn <mxn@1ec5.org> | 2015-05-08 11:51:48 -0700 |
---|---|---|
committer | Minh Nguyễn <mxn@1ec5.org> | 2015-05-08 11:51:48 -0700 |
commit | bb788f56f268cfebba2105be7e23744779cad7b8 (patch) | |
tree | b29ef0330a243cb50d8dea8d62b59cc04552347f /platform | |
parent | 1cf5af9c3155ea3e7261cf85be2004a528ac3763 (diff) | |
download | qtlocation-mapboxgl-bb788f56f268cfebba2105be7e23744779cad7b8.tar.gz |
Renamed settings keys
The new keys fit the standard naming convention for Info.plist keys and more clearly communicate how they’re to be used.
Diffstat (limited to 'platform')
-rw-r--r-- | platform/darwin/http_request_nsurl.mm | 2 | ||||
-rw-r--r-- | platform/ios/MGLMapboxEvents.m | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/platform/darwin/http_request_nsurl.mm b/platform/darwin/http_request_nsurl.mm index 0006dbef80..5ab4e1b43e 100644 --- a/platform/darwin/http_request_nsurl.mm +++ b/platform/darwin/http_request_nsurl.mm @@ -154,7 +154,7 @@ void HTTPRequest::start() { @autoreleasepool { NSMutableString *url = [NSMutableString stringWithString:@(resource.url.c_str())]; - if ([[NSUserDefaults standardUserDefaults] objectForKey:@"mapbox_metrics_disabled"] == nil) { + if ([[NSUserDefaults standardUserDefaults] integerForKey:@"MGLMapboxAccountType"] == 0) { if ([url rangeOfString:@"?"].location == NSNotFound) { [url appendString:@"?"]; } else { diff --git a/platform/ios/MGLMapboxEvents.m b/platform/ios/MGLMapboxEvents.m index 93891217ca..fe19291ab0 100644 --- a/platform/ios/MGLMapboxEvents.m +++ b/platform/ios/MGLMapboxEvents.m @@ -221,7 +221,7 @@ NSString *const MGLEventGestureRotateStart = @"Rotation"; static MGLMapboxEvents *_sharedManager; dispatch_once(&onceToken, ^{ if ( ! NSProcessInfo.processInfo.mgl_isInterfaceBuilderDesignablesAgent && - [[NSUserDefaults standardUserDefaults] objectForKey:@"mapbox_metrics_disabled"] == nil) { + [[NSUserDefaults standardUserDefaults] integerForKey:@"MGLMapboxAccountType"] == 0) { void (^setupBlock)() = ^{ _sharedManager = [[self alloc] init]; }; @@ -326,8 +326,8 @@ NSString *const MGLEventGestureRotateStart = @"Rotation"; MGLMapboxEvents *strongSelf = weakSelf; if ( ! strongSelf) return; - // Opt Out Checking When Built - if (![[NSUserDefaults standardUserDefaults] boolForKey:@"mapbox_metrics_enabled_preference"]) { + // User has opted out + if (![[NSUserDefaults standardUserDefaults] boolForKey:@"MGLMapboxMetricsEnabled"]) { [_eventQueue removeAllObjects]; return; } |