diff --git a/Vector/ViewController/AttachmentsViewController.m b/Vector/ViewController/AttachmentsViewController.m index 4a59af3b1..c69d491d5 100644 --- a/Vector/ViewController/AttachmentsViewController.m +++ b/Vector/ViewController/AttachmentsViewController.m @@ -26,10 +26,9 @@ #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; @@ -37,6 +36,12 @@ self.rageShakeManager = [RageShakeManager sharedManager]; } +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. +} + - (void)viewWillAppear:(BOOL)animated { [super viewWillAppear:animated]; diff --git a/Vector/ViewController/AuthenticationViewController.m b/Vector/ViewController/AuthenticationViewController.m index 9e69abde1..df18a787b 100644 --- a/Vector/ViewController/AuthenticationViewController.m +++ b/Vector/ViewController/AuthenticationViewController.m @@ -52,14 +52,19 @@ #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; self.mainNavigationItem.title = nil; self.rightBarButtonItem.title = NSLocalizedStringFromTable(@"auth_register", @"Vector", nil); diff --git a/Vector/ViewController/CallViewController.m b/Vector/ViewController/CallViewController.m index e73367cb5..a7ed83d30 100644 --- a/Vector/ViewController/CallViewController.m +++ b/Vector/ViewController/CallViewController.m @@ -18,6 +18,8 @@ #import "AppDelegate.h" +#import "RageShakeManager.h" + #import "AvatarGenerator.h" #import "VectorDesignValues.h" @@ -64,6 +66,16 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; +} + - (void)viewDidLoad { [super viewDidLoad]; diff --git a/Vector/ViewController/ContactDetailsViewController.m b/Vector/ViewController/ContactDetailsViewController.m index da45d78a9..96ffa13dd 100644 --- a/Vector/ViewController/ContactDetailsViewController.m +++ b/Vector/ViewController/ContactDetailsViewController.m @@ -98,6 +98,16 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; +} + - (void)viewDidLoad { [super viewDidLoad]; @@ -113,11 +123,6 @@ actionsArray = [[NSMutableArray alloc] init]; directChatsArray = [[NSMutableArray alloc] init]; - // Setup `MXKViewControllerHandling` properties - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - self.rageShakeManager = [RageShakeManager sharedManager]; - self.headerView.backgroundColor = kVectorColorLightGrey; self.contactNameLabel.textColor = kVectorTextColorBlack; self.contactStatusLabel.textColor = kVectorColorGreen; diff --git a/Vector/ViewController/ContactPickerViewController.m b/Vector/ViewController/ContactPickerViewController.m index c298b8054..806fb2af1 100644 --- a/Vector/ViewController/ContactPickerViewController.m +++ b/Vector/ViewController/ContactPickerViewController.m @@ -60,6 +60,16 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; +} + - (void)viewDidLoad { [super viewDidLoad]; @@ -70,11 +80,6 @@ // Instantiate view controller objects [[[self class] nib] instantiateWithOwner:self options:nil]; } - - // Setup `MXKViewControllerHandling` properties - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - self.rageShakeManager = [RageShakeManager sharedManager]; [self.contactsTableView registerNib:ContactTableViewCell.nib forCellReuseIdentifier:ContactTableViewCell.defaultReuseIdentifier]; diff --git a/Vector/ViewController/DirectoryViewController.m b/Vector/ViewController/DirectoryViewController.m index 31106617e..9e9ccf413 100644 --- a/Vector/ViewController/DirectoryViewController.m +++ b/Vector/ViewController/DirectoryViewController.m @@ -36,14 +36,19 @@ @implementation DirectoryViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; self.title = NSLocalizedStringFromTable(@"directory_title", @"Vector", nil); diff --git a/Vector/ViewController/HomeFilesSearchViewController.m b/Vector/ViewController/HomeFilesSearchViewController.m index 2ee22e550..970390a3f 100644 --- a/Vector/ViewController/HomeFilesSearchViewController.m +++ b/Vector/ViewController/HomeFilesSearchViewController.m @@ -31,14 +31,19 @@ @implementation HomeFilesSearchViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; // Register cell class used to display the files search result [self.searchTableView registerClass:FilesSearchTableViewCell.class forCellReuseIdentifier:FilesSearchTableViewCell.defaultReuseIdentifier]; diff --git a/Vector/ViewController/HomeMessagesSearchViewController.m b/Vector/ViewController/HomeMessagesSearchViewController.m index b279b2a13..69f7bf734 100644 --- a/Vector/ViewController/HomeMessagesSearchViewController.m +++ b/Vector/ViewController/HomeMessagesSearchViewController.m @@ -35,14 +35,19 @@ @implementation HomeMessagesSearchViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; // Reuse cells from the RoomViewController to display results [self.searchTableView registerClass:MessagesSearchResultTextMsgBubbleCell.class forCellReuseIdentifier:MessagesSearchResultTextMsgBubbleCell.defaultReuseIdentifier]; diff --git a/Vector/ViewController/HomeViewController.m b/Vector/ViewController/HomeViewController.m index 6b71f8d3d..f15b4c5c5 100644 --- a/Vector/ViewController/HomeViewController.m +++ b/Vector/ViewController/HomeViewController.m @@ -80,6 +80,13 @@ @implementation HomeViewController +- (void)finalizeInit +{ + [super finalizeInit]; + + // The navigation bar tint color and the rageShake Manager are handled by super (see SegmentedViewController). +} + - (void)viewDidLoad { // Set up the SegmentedVC tabs before calling [super viewDidLoad] @@ -110,8 +117,6 @@ [super viewDidLoad]; - // The navigation bar tint color and the rageShake Manager are handled by super (see SegmentedViewController) - self.navigationItem.title = NSLocalizedStringFromTable(@"title_recents", @"Vector", nil); // Add the Vector background image when search bar is empty diff --git a/Vector/ViewController/MediaAlbumContentViewController.m b/Vector/ViewController/MediaAlbumContentViewController.m index 6902a65e6..72ac1b180 100644 --- a/Vector/ViewController/MediaAlbumContentViewController.m +++ b/Vector/ViewController/MediaAlbumContentViewController.m @@ -60,15 +60,20 @@ #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. // Register collection view cell class [self.assetsCollectionView registerClass:MXKMediaCollectionViewCell.class forCellWithReuseIdentifier:[MXKMediaCollectionViewCell defaultReuseIdentifier]]; diff --git a/Vector/ViewController/MediaPickerViewController.m b/Vector/ViewController/MediaPickerViewController.m index 8dcacbea5..5d821689b 100644 --- a/Vector/ViewController/MediaPickerViewController.m +++ b/Vector/ViewController/MediaPickerViewController.m @@ -102,10 +102,9 @@ static void *RecordingContext = &RecordingContext; #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; @@ -114,6 +113,12 @@ static void *RecordingContext = &RecordingContext; cameraQueue = dispatch_queue_create("media.picker.vc.camera", NULL); canToggleCamera = YES; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. // Register collection view cell class [self.recentCapturesCollectionView registerClass:MXKMediaCollectionViewCell.class forCellWithReuseIdentifier:[MXKMediaCollectionViewCell defaultReuseIdentifier]]; diff --git a/Vector/ViewController/RecentsViewController.m b/Vector/ViewController/RecentsViewController.m index 3d9a906cf..94d879814 100644 --- a/Vector/ViewController/RecentsViewController.m +++ b/Vector/ViewController/RecentsViewController.m @@ -79,15 +79,20 @@ self.navigationItem.title = NSLocalizedStringFromTable(@"title_recents", @"Vector", nil); } -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. // Register here the customized cell view class used to render recents [self.recentsTableView registerNib:RecentTableViewCell.nib forCellReuseIdentifier:RecentTableViewCell.defaultReuseIdentifier]; diff --git a/Vector/ViewController/RoomFilesSearchViewController.m b/Vector/ViewController/RoomFilesSearchViewController.m index 04c59a5c0..78e19995d 100644 --- a/Vector/ViewController/RoomFilesSearchViewController.m +++ b/Vector/ViewController/RoomFilesSearchViewController.m @@ -39,14 +39,19 @@ @implementation RoomFilesSearchViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; // Hide line separators of empty cells self.searchTableView.tableFooterView = [[UIView alloc] init]; diff --git a/Vector/ViewController/RoomFilesViewController.m b/Vector/ViewController/RoomFilesViewController.m index 441e0c69e..92f03feb3 100644 --- a/Vector/ViewController/RoomFilesViewController.m +++ b/Vector/ViewController/RoomFilesViewController.m @@ -52,6 +52,16 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; +} + - (void)viewDidLoad { [super viewDidLoad]; @@ -67,9 +77,6 @@ // set the default extra [self setRoomActivitiesViewClass:nil]; - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - // Register first customized cell view classes used to render bubbles [self.bubblesTableView registerClass:FilesSearchTableViewCell.class forCellReuseIdentifier:FilesSearchTableViewCell.defaultReuseIdentifier]; diff --git a/Vector/ViewController/RoomMemberDetailsViewController.m b/Vector/ViewController/RoomMemberDetailsViewController.m index e59afae73..797fa293a 100644 --- a/Vector/ViewController/RoomMemberDetailsViewController.m +++ b/Vector/ViewController/RoomMemberDetailsViewController.m @@ -90,20 +90,25 @@ #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. - - adminActionsArray = [[NSMutableArray alloc] init]; - otherActionsArray = [[NSMutableArray alloc] init]; - directChatsArray = [[NSMutableArray alloc] init]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; + adminActionsArray = [[NSMutableArray alloc] init]; + otherActionsArray = [[NSMutableArray alloc] init]; + directChatsArray = [[NSMutableArray alloc] init]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. + self.memberHeaderView.backgroundColor = kVectorColorLightGrey; self.roomMemberNameLabel.textColor = kVectorTextColorBlack; self.roomMemberStatusLabel.textColor = kVectorColorGreen; diff --git a/Vector/ViewController/RoomMessagesSearchViewController.m b/Vector/ViewController/RoomMessagesSearchViewController.m index 3400572df..9bf2629fc 100644 --- a/Vector/ViewController/RoomMessagesSearchViewController.m +++ b/Vector/ViewController/RoomMessagesSearchViewController.m @@ -41,14 +41,19 @@ @implementation RoomMessagesSearchViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; // Hide line separators of empty cells self.searchTableView.tableFooterView = [[UIView alloc] init]; diff --git a/Vector/ViewController/RoomParticipantsViewController.m b/Vector/ViewController/RoomParticipantsViewController.m index 207835e59..807a7011d 100644 --- a/Vector/ViewController/RoomParticipantsViewController.m +++ b/Vector/ViewController/RoomParticipantsViewController.m @@ -89,6 +89,18 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; + + _isAddParticipantSearchBarEditing = NO; +} + - (void)viewDidLoad { [super viewDidLoad]; @@ -122,11 +134,6 @@ [NSLayoutConstraint activateConstraints:@[_searchBarTopConstraint, _tableViewBottomConstraint]]; - // Setup `MXKViewControllerHandling` properties - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - self.rageShakeManager = [RageShakeManager sharedManager]; - self.navigationItem.title = NSLocalizedStringFromTable(@"room_participants_title", @"Vector", nil); // Add each matrix session, to update the view controller appearance according to mx sessions state @@ -136,8 +143,6 @@ [self addMatrixSession:mxSession]; } - _isAddParticipantSearchBarEditing = NO; - _searchBarView.placeholder = NSLocalizedStringFromTable(@"room_participants_invite_another_user", @"Vector", nil); _searchBarView.returnKeyType = UIReturnKeyDone; _searchBarView.autocapitalizationType = UITextAutocapitalizationTypeNone; diff --git a/Vector/ViewController/RoomSearchViewController.m b/Vector/ViewController/RoomSearchViewController.m index 7062b0341..1892c29c3 100644 --- a/Vector/ViewController/RoomSearchViewController.m +++ b/Vector/ViewController/RoomSearchViewController.m @@ -37,6 +37,13 @@ @implementation RoomSearchViewController +- (void)finalizeInit +{ + [super finalizeInit]; + + // The navigation bar tint color and the rageShake Manager are handled by super (see SegmentedViewController). +} + - (void)viewDidLoad { // Set up the SegmentedVC tabs before calling [super viewDidLoad] @@ -56,8 +63,6 @@ [super viewDidLoad]; - // The navigation bar tint color and the rageShake Manager are handled by super (see SegmentedViewController) - // Add the Vector background image when search bar is empty [self addBackgroundImageViewToView:self.view]; diff --git a/Vector/ViewController/RoomSettingsViewController.m b/Vector/ViewController/RoomSettingsViewController.m index 0c1bc34d1..fee96a796 100644 --- a/Vector/ViewController/RoomSettingsViewController.m +++ b/Vector/ViewController/RoomSettingsViewController.m @@ -156,6 +156,11 @@ NSString *const kRoomSettingsAdvancedE2eEnabledCellViewIdentifier = @"kRoomSetti [super finalizeInit]; _selectedRoomSettingsField = RoomSettingsViewControllerFieldNone; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; } - (void)initWithSession:(MXSession *)session andRoomId:(NSString *)roomId @@ -198,11 +203,6 @@ NSString *const kRoomSettingsAdvancedE2eEnabledCellViewIdentifier = @"kRoomSetti { [super viewDidLoad]; - // Setup `MXKViewControllerHandling` properties - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - self.rageShakeManager = [RageShakeManager sharedManager]; - updatedItemsDict = [[NSMutableDictionary alloc] init]; historyVisibilityTickCells = [[NSMutableDictionary alloc] initWithCapacity:4]; diff --git a/Vector/ViewController/RoomViewController.m b/Vector/ViewController/RoomViewController.m index f6d9d4000..4c8e41c60 100644 --- a/Vector/ViewController/RoomViewController.m +++ b/Vector/ViewController/RoomViewController.m @@ -206,13 +206,20 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; +} + - (void)viewDidLoad { [super viewDidLoad]; - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - // Register first customized cell view classes used to render bubbles [self.bubblesTableView registerClass:RoomIncomingTextMsgBubbleCell.class forCellReuseIdentifier:RoomIncomingTextMsgBubbleCell.defaultReuseIdentifier]; [self.bubblesTableView registerClass:RoomIncomingTextMsgWithoutSenderInfoBubbleCell.class forCellReuseIdentifier:RoomIncomingTextMsgWithoutSenderInfoBubbleCell.defaultReuseIdentifier]; @@ -309,9 +316,6 @@ // Custom the attachmnet viewer [self setAttachmentsViewerClass:AttachmentsViewController.class]; - // Set rageShake handler - self.rageShakeManager = [RageShakeManager sharedManager]; - // Update navigation bar items self.navigationItem.rightBarButtonItem.target = self; self.navigationItem.rightBarButtonItem.action = @selector(onButtonPressed:); diff --git a/Vector/ViewController/SegmentedViewController.m b/Vector/ViewController/SegmentedViewController.m index 0d223824e..4d3132603 100644 --- a/Vector/ViewController/SegmentedViewController.m +++ b/Vector/ViewController/SegmentedViewController.m @@ -115,14 +115,19 @@ #pragma mark - -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; // Check whether the view controller has been pushed via storyboard if (!self.viewControllerContainer) diff --git a/Vector/ViewController/SettingsViewController.m b/Vector/ViewController/SettingsViewController.m index 091b3d8c0..47f6b64fd 100644 --- a/Vector/ViewController/SettingsViewController.m +++ b/Vector/ViewController/SettingsViewController.m @@ -151,16 +151,25 @@ typedef void (^blockSettingsViewController_onReadyToDestroy)(); @implementation SettingsViewController -- (void)viewDidLoad +- (void)finalizeInit { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. + [super finalizeInit]; // Setup `MXKViewControllerHandling` properties self.defaultBarTintColor = kVectorNavBarTintColor; self.enableBarTintColorStatusChange = NO; self.rageShakeManager = [RageShakeManager sharedManager]; + isSavingInProgress = NO; + isResetPwdInProgress = NO; + isEmailBindingInProgress = NO; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. + self.navigationItem.title = NSLocalizedStringFromTable(@"settings_title", @"Vector", nil); self.tableView.backgroundColor = kVectorColorLightGrey; @@ -196,7 +205,6 @@ typedef void (^blockSettingsViewController_onReadyToDestroy)(); }]; - // Add each matrix session, to update the view controller appearance according to mx sessions state NSArray *sessions = [AppDelegate theDelegate].mxSessions; for (MXSession *mxSession in sessions) diff --git a/Vector/ViewController/StartChatViewController.m b/Vector/ViewController/StartChatViewController.m index 1516cb7c6..9cc9576af 100644 --- a/Vector/ViewController/StartChatViewController.m +++ b/Vector/ViewController/StartChatViewController.m @@ -82,6 +82,21 @@ #pragma mark - +- (void)finalizeInit +{ + [super finalizeInit]; + + // Setup `MXKViewControllerHandling` properties + self.defaultBarTintColor = kVectorNavBarTintColor; + self.enableBarTintColorStatusChange = NO; + self.rageShakeManager = [RageShakeManager sharedManager]; + + _isAddParticipantSearchBarEditing = NO; + + // Prepare room participants + participants = [NSMutableArray array]; +} + - (void)viewDidLoad { [super viewDidLoad]; @@ -115,11 +130,6 @@ [NSLayoutConstraint activateConstraints:@[_searchBarTopConstraint, _tableViewBottomConstraint]]; - // Setup `MXKViewControllerHandling` properties - self.defaultBarTintColor = kVectorNavBarTintColor; - self.enableBarTintColorStatusChange = NO; - self.rageShakeManager = [RageShakeManager sharedManager]; - self.navigationItem.title = NSLocalizedStringFromTable(@"room_creation_title", @"Vector", nil); cancelBarButtonItem = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemCancel target:self action:@selector(onButtonPressed:)]; @@ -135,8 +145,6 @@ [self addMatrixSession:mxSession]; } - _isAddParticipantSearchBarEditing = NO; - _searchBarView.placeholder = NSLocalizedStringFromTable(@"room_participants_invite_another_user", @"Vector", nil); _searchBarView.returnKeyType = UIReturnKeyDone; _searchBarView.autocapitalizationType = UITextAutocapitalizationTypeNone; @@ -147,9 +155,6 @@ // Hide line separators of empty cells self.tableView.tableFooterView = [[UIView alloc] init]; - // Prepare room participants - participants = [NSMutableArray array]; - // FIXME: Handle multi accounts NSString *displayName = NSLocalizedStringFromTable(@"you", @"Vector", nil); userContact = [[MXKContact alloc] initMatrixContactWithDisplayName:displayName andMatrixID:self.mainSession.myUser.userId];