diff options
author | Brad Leege <bleege@gmail.com> | 2015-03-31 09:46:28 -0500 |
---|---|---|
committer | Brad Leege <bleege@gmail.com> | 2015-03-31 09:46:28 -0500 |
commit | adcbf48ff52fee5a0632dce7fc884224a13dc864 (patch) | |
tree | fa57f485bab2bc9c3c4cee99634a3569726796d2 /platform/ios | |
parent | 48a987c373990279a3332fe69927d507600269a2 (diff) | |
download | qtlocation-mapboxgl-adcbf48ff52fee5a0632dce7fc884224a13dc864.tar.gz |
#1162 - Adding appBundleId as an event attribute
Diffstat (limited to 'platform/ios')
-rw-r--r-- | platform/ios/MGLMapboxEvents.m | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/platform/ios/MGLMapboxEvents.m b/platform/ios/MGLMapboxEvents.m index ce59815372..7b810d5cd5 100644 --- a/platform/ios/MGLMapboxEvents.m +++ b/platform/ios/MGLMapboxEvents.m @@ -59,6 +59,7 @@ NSString *const MGLEventGestureRotateStart = @"Rotation"; @property (atomic) NSString *instanceID; @property (atomic) NSString *advertiserId; @property (atomic) NSString *vendorId; +@property (atomic) NSString *appBundleId; @property (atomic) NSString *userAgent; @property (atomic) NSString *model; @property (atomic) NSString *iOSVersion; @@ -115,9 +116,9 @@ NSString *const MGLEventGestureRotateStart = @"Rotation"; [[NSUserDefaults standardUserDefaults] registerDefaults:defaultsToRegister]; } - NSString *bundleID = [[NSBundle mainBundle] bundleIdentifier]; + _appBundleId = [[NSBundle mainBundle] bundleIdentifier]; NSString *uniqueID = [[NSProcessInfo processInfo] globallyUniqueString]; - _serialQueue = dispatch_queue_create([[NSString stringWithFormat:@"%@.%@.events.serial", bundleID, uniqueID] UTF8String], DISPATCH_QUEUE_SERIAL); + _serialQueue = dispatch_queue_create([[NSString stringWithFormat:@"%@.%@.events.serial", _appBundleId, uniqueID] UTF8String], DISPATCH_QUEUE_SERIAL); // Configure Events Infrastructure _eventQueue = [[NSMutableArray alloc] init]; @@ -248,6 +249,7 @@ NSString *const MGLEventGestureRotateStart = @"Rotation"; [evt setObject:weakSelf.instanceID forKey:@"instance"]; [evt setObject:weakSelf.advertiserId forKey:@"advertiserId"]; [evt setObject:weakSelf.vendorId forKey:@"vendorId"]; + [evt setObject:weakSelf.appBundleId forKeyedSubscript:@"appBundleId"]; // mapbox-events-ios stock attributes [evt setValue:[weakSelf.rfc3339DateFormatter stringFromDate:[NSDate date]] forKey:@"created"]; |