Add AnalyticsScreenTimer and track more screens.

Update Analytics with new methods in MXAnalyticsDelegate.
This commit is contained in:
Doug
2021-12-02 14:25:45 +00:00
parent 418865a388
commit 315f5a9cc4
42 changed files with 513 additions and 42 deletions
@@ -104,6 +104,8 @@
@property(nonatomic, strong) UserVerificationCoordinatorBridgePresenter *userVerificationCoordinatorBridgePresenter;
@property(nonatomic) AnalyticsScreenTimer *screenTimer;
@end
@implementation RoomMemberDetailsViewController
@@ -139,6 +141,8 @@
// Keep visible the status bar by default.
isStatusBarHidden = NO;
self.screenTimer = [[AnalyticsScreenTimer alloc] initWithScreen:AnalyticsScreenUser];
}
- (void)viewDidLoad
@@ -239,9 +243,6 @@
{
[super viewWillAppear:animated];
// Screen tracking
[Analytics.shared trackScreen:AnalyticsScreenUser];
[self userInterfaceThemeDidChange];
// Hide the bottom border of the navigation bar to display the expander header
@@ -264,6 +265,18 @@
self.bottomImageView.hidden = YES;
}
- (void)viewDidAppear:(BOOL)animated
{
[super viewDidAppear:animated];
[self.screenTimer start];
}
- (void)viewDidDisappear:(BOOL)animated
{
[super viewDidDisappear:animated];
[self.screenTimer stop];
}
- (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id <UIViewControllerTransitionCoordinator>)coordinator
{
[super viewWillTransitionToSize:size withTransitionCoordinator:coordinator];