Use protocol to get title from child VCs.

This commit is contained in:
David Langley
2022-02-23 11:41:05 +00:00
parent 3fa694552e
commit 9c53cfd4e3
8 changed files with 75 additions and 17 deletions
+8 -3
View File
@@ -26,7 +26,7 @@
#import "GeneratedInterface-Swift.h"
@interface PeopleViewController () <SpaceMembersCoordinatorBridgePresenterDelegate>
@interface PeopleViewController () <SpaceMembersCoordinatorBridgePresenterDelegate, MasterTabBarItemDisplayProtocol>
{
NSInteger directRoomsSectionNumber;
RecentsDataSource *recentsDataSource;
@@ -83,8 +83,6 @@
- (void)viewWillAppear:(BOOL)animated
{
[super viewWillAppear:animated];
[AppDelegate theDelegate].masterTabBarController.navigationItem.title = [VectorL10n titlePeople];
[AppDelegate theDelegate].masterTabBarController.tabBar.tintColor = ThemeService.shared.theme.tintColor;
if ([self.dataSource isKindOfClass:RecentsDataSource.class])
@@ -194,4 +192,11 @@
}];
}
#pragma mark - MasterTabBarItemDisplayProtocol
- (NSString *)masterTabBarItemTitle
{
return [VectorL10n titlePeople];
}
@end