diff options
author | Alex Zolotarev <alex@maps.me> | 2015-08-10 09:08:21 +0300 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 03:00:19 +0300 |
commit | 846d57d67b9b5d30a12df624ff3c8503b3e21608 (patch) | |
tree | 211681dd6e49e4ae1528fbd191f4b81b83f03661 /iphone | |
parent | 26f51d1aa3ba27af0ac4124fbe2674670c25d848 (diff) |
[ios] Renamed FB events by Alexander Bobko’s request for probably easier tracking in the FB admin panel.
Diffstat (limited to 'iphone')
-rw-r--r-- | iphone/Maps/Statistics/MWMCustomFacebookEvents.mm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/iphone/Maps/Statistics/MWMCustomFacebookEvents.mm b/iphone/Maps/Statistics/MWMCustomFacebookEvents.mm index f3c420da62..122edc5900 100644 --- a/iphone/Maps/Statistics/MWMCustomFacebookEvents.mm +++ b/iphone/Maps/Statistics/MWMCustomFacebookEvents.mm @@ -10,11 +10,12 @@ // Used to filter out old users and to track only new installs. static NSString * const kEnableCustomFBEventsForNewUsers = @"FBEnableCustomEventsForNewUsers"; // Special one-time events to improve marketing targeting. -static NSString * const kFirstSessionIsLongerThanXMinutesEvent = @"FBLongFirstSession"; +// NOTE: Event names are using some default FB names by Alexander Bobko's request. +static NSString * const kFirstSessionIsLongerThanXMinutesEvent = FBSDKAppEventNameAchievedLevel; static NSInteger const kFirstSessionLengthInSeconds = 5 * 60; -static NSString * const kNextLaunchAfterHoursInterval = @"FBLaunchedAgainInAFewHoursAfterInstall"; +static NSString * const kNextLaunchAfterHoursInterval = FBSDKAppEventNameCompletedRegistration; static NSInteger const kNextLaunchMinHoursInterval = 6; -static NSString * const kDownloadedSecondMapEvent = @"FBDownloadedSecondMap"; +static NSString * const kDownloadedSecondMapEvent = FBSDKAppEventNameUnlockedAchievement; static constexpr int kNotSubscribed = -1; static int gStorageSubscriptionId = kNotSubscribed; @@ -32,7 +33,8 @@ static int gStorageSubscriptionId = kNotSubscribed; [[NSNotificationCenter defaultCenter] removeObserver:[MWMCustomFacebookEvents class]]; NSInteger const seconds = [Alohalytics totalSecondsSpentInTheApp]; if (seconds >= kFirstSessionLengthInSeconds) - [FBSDKAppEvents logEvent:kFirstSessionIsLongerThanXMinutesEvent parameters:@{@"Minutes" : [NSNumber numberWithInteger:(seconds / 60)]}]; + [FBSDKAppEvents logEvent:kFirstSessionIsLongerThanXMinutesEvent + parameters:@{FBSDKAppEventParameterNameLevel : [NSNumber numberWithInteger:(seconds / 60)]}]; [MWMCustomFacebookEvents markEventAsAlreadyFired:kFirstSessionIsLongerThanXMinutesEvent]; } |