Analytics: Create a generic API in AppDelegate class

And move all Google Analytics code to AppDelegate.m
This commit is contained in:
manuroe
2017-12-22 13:19:40 +01:00
parent 062ed97457
commit e1b5675485
26 changed files with 96 additions and 199 deletions
@@ -114,14 +114,9 @@
- (void)viewWillAppear:(BOOL)animated
{
[super viewWillAppear:animated];
// Screen tracking (via Google Analytics)
id<GAITracker> tracker = [[GAI sharedInstance] defaultTracker];
if (tracker)
{
[tracker set:kGAIScreenName value:@"UnknowDevices"];
[tracker send:[[GAIDictionaryBuilder createScreenView] build]];
}
// Screen tracking
[[AppDelegate theDelegate] trackScreen:@"UnknowDevices"];
[self.tableView reloadData];
}