Merge remote-tracking branch 'origin/develop' into riot_887

# Conflicts:
#	Vector/ViewController/StartChatViewController.m
This commit is contained in:
giomfo 2017-01-05 09:59:25 +01:00
commit 5c17d3fb3c
23 changed files with 209 additions and 88 deletions

View file

@ -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];

View file

@ -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);

View file

@ -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];

View file

@ -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;

View file

@ -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];

View file

@ -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);

View file

@ -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];

View file

@ -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];

View file

@ -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

View file

@ -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]];

View file

@ -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]];

View file

@ -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];

View file

@ -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];

View file

@ -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];

View file

@ -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;

View file

@ -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];

View file

@ -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;

View file

@ -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];

View file

@ -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];

View file

@ -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:);

View file

@ -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)

View file

@ -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)

View file

@ -85,6 +85,27 @@
#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];
// Prepare search session
searchProcessingQueue = dispatch_queue_create("StartChatViewController", DISPATCH_QUEUE_SERIAL);
searchProcessingCount = 0;
searchProcessingText = nil;
searchProcessingContacts = nil;
}
- (void)viewDidLoad
{
[super viewDidLoad];
@ -118,11 +139,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:)];
@ -138,8 +154,6 @@
[self addMatrixSession:mxSession];
}
_isAddParticipantSearchBarEditing = NO;
_searchBarView.placeholder = NSLocalizedStringFromTable(@"room_participants_invite_another_user", @"Vector", nil);
_searchBarView.returnKeyType = UIReturnKeyDone;
_searchBarView.autocapitalizationType = UITextAutocapitalizationTypeNone;
@ -150,15 +164,6 @@
// Hide line separators of empty cells
self.tableView.tableFooterView = [[UIView alloc] init];
// Prepare room participants
participants = [NSMutableArray array];
// Prepare search session
searchProcessingQueue = dispatch_queue_create("StartChatViewController", DISPATCH_QUEUE_SERIAL);
searchProcessingCount = 0;
searchProcessingText = nil;
searchProcessingContacts = nil;
// FIXME: Handle multi accounts
NSString *displayName = NSLocalizedStringFromTable(@"you", @"Vector", nil);
userContact = [[MXKContact alloc] initMatrixContactWithDisplayName:displayName andMatrixID:self.mainSession.myUser.userId];