forked from mirrors/linphone-iphone
[Release] v.16.5 build 10
This commit is contained in:
parent
a2b245612e
commit
d4da217ce5
4 changed files with 87 additions and 93 deletions
15
CHANGELOG.md
15
CHANGELOG.md
|
|
@ -10,6 +10,21 @@ Group changes to describe their impact on the project, as follows:
|
|||
Fixed for any bug fixes.
|
||||
Security to invite users to upgrade in case of vulnerabilities.
|
||||
|
||||
## [3.16.5] - 2017-11-28
|
||||
|
||||
### Added
|
||||
- Support of IOS 11
|
||||
|
||||
### Changed
|
||||
- Contact, CNContact implmentation.
|
||||
- Contacts loading optimization.
|
||||
- Sound management updated
|
||||
|
||||
### Fixed
|
||||
- Chat file resend fixed
|
||||
- Minor bugs fixes
|
||||
- Audio fixed on conference call
|
||||
|
||||
## [3.16.3] - 2017-05-03
|
||||
|
||||
### Added
|
||||
|
|
|
|||
|
|
@ -134,103 +134,81 @@ static int ms_strcmpfuz(const char *fuzzy_word, const char *sentence) {
|
|||
addressBookMap = [LinphoneManager.instance getLinphoneManagerAddressBookMap];
|
||||
BOOL updated = [LinphoneManager.instance getContactsUpdated];
|
||||
if(([previous isEqualToString:@"ContactsDetailsView"] && updated) || updated || [addressBookMap count] == 0){
|
||||
[LinphoneManager.instance setContactsUpdated:FALSE];
|
||||
@synchronized(addressBookMap) {
|
||||
//Set all contacts from ContactCell to nil
|
||||
for (NSInteger j = 0; j < [self.tableView numberOfSections]; ++j)
|
||||
{
|
||||
for (NSInteger i = 0; i < [self.tableView numberOfRowsInSection:j]; ++i)
|
||||
[LinphoneManager.instance setContactsUpdated:FALSE];
|
||||
@synchronized(addressBookMap) {
|
||||
//Set all contacts from ContactCell to nil
|
||||
for (NSInteger j = 0; j < [self.tableView numberOfSections]; ++j)
|
||||
{
|
||||
[[self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:i inSection:j]] setContact:nil];
|
||||
for (NSInteger i = 0; i < [self.tableView numberOfRowsInSection:j]; ++i)
|
||||
{
|
||||
[[self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:i inSection:j]] setContact:nil];
|
||||
}
|
||||
}
|
||||
|
||||
// Reset Address book
|
||||
[addressBookMap removeAllObjects];
|
||||
for (NSString *addr in LinphoneManager.instance.fastAddressBook.addressBookMap) {
|
||||
Contact *contact = nil;
|
||||
@synchronized(LinphoneManager.instance.fastAddressBook.addressBookMap) {
|
||||
contact = [LinphoneManager.instance.fastAddressBook.addressBookMap objectForKey:addr];
|
||||
}
|
||||
BOOL add = true;
|
||||
// Do not add the contact directly if we set some filter
|
||||
if ([ContactSelection getSipFilter] ||
|
||||
[ContactSelection emailFilterEnabled]) {
|
||||
add = false;
|
||||
}else if ([FastAddressBook contactHasValidSipDomain:contact]) {
|
||||
add = true;
|
||||
}else if (contact.friend &&
|
||||
linphone_presence_model_get_basic_status(
|
||||
linphone_friend_get_presence_model(
|
||||
contact.friend)) ==
|
||||
LinphonePresenceBasicStatusOpen) {
|
||||
add = true;
|
||||
}
|
||||
|
||||
if (!add && [ContactSelection emailFilterEnabled]) {
|
||||
// Add this contact if it has an email
|
||||
add = (contact.emails.count > 0);
|
||||
}
|
||||
|
||||
NSMutableString *name = [self displayNameForContact:contact] ? [[NSMutableString alloc] initWithString: [self displayNameForContact:contact]] : nil;
|
||||
if (add && name != nil) {
|
||||
NSString *firstChar = [[name substringToIndex:1] uppercaseString];
|
||||
// Put in correct subAr
|
||||
if ([firstChar characterAtIndex:0] < 'A' || [firstChar characterAtIndex:0] > 'Z') {
|
||||
firstChar = @"#";
|
||||
}
|
||||
NSMutableArray *subAr = [addressBookMap objectForKey:firstChar];
|
||||
if (subAr == nil) {
|
||||
subAr = [[NSMutableArray alloc] init];
|
||||
[addressBookMap insertObject:subAr forKey:firstChar selector:@selector(caseInsensitiveCompare:)];
|
||||
}
|
||||
NSUInteger idx = [subAr indexOfObject:contact inSortedRange:(NSRange){0, subAr.count} options:NSBinarySearchingInsertionIndex usingComparator:^NSComparisonResult( Contact *_Nonnull obj1, Contact *_Nonnull obj2) {
|
||||
return [[self displayNameForContact:obj1] compare:[self displayNameForContact:obj2] options:NSCaseInsensitiveSearch];
|
||||
}];
|
||||
if (![subAr containsObject:contact]) {
|
||||
[subAr insertObject:contact atIndex:idx];
|
||||
}
|
||||
}
|
||||
//}
|
||||
}
|
||||
[super loadData];
|
||||
|
||||
// since we refresh the tableview, we must perform this on main
|
||||
// thread
|
||||
dispatch_async(dispatch_get_main_queue(), ^(void) {
|
||||
if (IPAD) {
|
||||
if (!([self totalNumberOfItems] > 0)) {
|
||||
ContactDetailsView *view = VIEW(ContactDetailsView);
|
||||
[view setContact:nil];
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// Reset Address book
|
||||
[addressBookMap removeAllObjects];
|
||||
for (NSString *addr in LinphoneManager.instance.fastAddressBook.addressBookMap) {
|
||||
@synchronized(
|
||||
LinphoneManager.instance.fastAddressBook.addressBookMap) {
|
||||
Contact *contact =
|
||||
[LinphoneManager.instance.fastAddressBook.addressBookMap
|
||||
objectForKey:addr];
|
||||
BOOL add = true;
|
||||
// Do not add the contact directly if we set some filter
|
||||
if ([ContactSelection getSipFilter] ||
|
||||
[ContactSelection emailFilterEnabled]) {
|
||||
add = false;
|
||||
}
|
||||
if ([FastAddressBook contactHasValidSipDomain:contact]) {
|
||||
add = true;
|
||||
}
|
||||
if (contact.friend &&
|
||||
linphone_presence_model_get_basic_status(
|
||||
linphone_friend_get_presence_model(
|
||||
contact.friend)) ==
|
||||
LinphonePresenceBasicStatusOpen) {
|
||||
add = true;
|
||||
}
|
||||
|
||||
if (!add && [ContactSelection emailFilterEnabled]) {
|
||||
// Add this contact if it has an email
|
||||
add = (contact.emails.count > 0);
|
||||
}
|
||||
|
||||
NSMutableString *name =
|
||||
[self displayNameForContact:contact]
|
||||
? [[NSMutableString alloc]
|
||||
initWithString:
|
||||
[self displayNameForContact:contact]]
|
||||
: nil;
|
||||
if (add && name != nil) {
|
||||
NSString *firstChar =
|
||||
[[name substringToIndex:1] uppercaseString];
|
||||
|
||||
// Put in correct subAr
|
||||
if ([firstChar characterAtIndex:0] < 'A' ||
|
||||
[firstChar characterAtIndex:0] > 'Z') {
|
||||
firstChar = @"#";
|
||||
}
|
||||
NSMutableArray *subAr =
|
||||
[addressBookMap objectForKey:firstChar];
|
||||
if (subAr == nil) {
|
||||
subAr = [[NSMutableArray alloc] init];
|
||||
[addressBookMap
|
||||
insertObject:subAr
|
||||
forKey:firstChar
|
||||
selector:@selector(caseInsensitiveCompare:)];
|
||||
}
|
||||
NSUInteger idx = [subAr
|
||||
indexOfObject:contact
|
||||
inSortedRange:(NSRange){0, subAr.count}
|
||||
options:NSBinarySearchingInsertionIndex
|
||||
usingComparator:^NSComparisonResult(
|
||||
Contact *_Nonnull obj1, Contact *_Nonnull obj2) {
|
||||
return [[self displayNameForContact:obj1]
|
||||
compare:[self displayNameForContact:obj2]
|
||||
options:NSCaseInsensitiveSearch];
|
||||
}];
|
||||
if (![subAr containsObject:contact]) {
|
||||
[subAr insertObject:contact atIndex:idx];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
[super loadData];
|
||||
|
||||
// since we refresh the tableview, we must perform this on main
|
||||
// thread
|
||||
dispatch_async(dispatch_get_main_queue(), ^(void) {
|
||||
if (IPAD) {
|
||||
if (!([self totalNumberOfItems] > 0)) {
|
||||
ContactDetailsView *view = VIEW(ContactDetailsView);
|
||||
[view setContact:nil];
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
[LinphoneManager.instance setLinphoneManagerAddressBookMap:addressBookMap];
|
||||
}
|
||||
_ongoing = FALSE;
|
||||
_ongoing = FALSE;
|
||||
}
|
||||
|
||||
- (void)loadSearchedData {
|
||||
|
|
|
|||
|
|
@ -158,6 +158,7 @@ static UICompositeViewDescription *compositeDescription = nil;
|
|||
- (void)changeView:(ContactsCategory)view {
|
||||
CGRect frame = _selectedButtonImage.frame;
|
||||
if (view == ContactsAll && !allButton.selected) {
|
||||
[LinphoneManager.instance setContactsUpdated:TRUE];
|
||||
frame.origin.x = allButton.frame.origin.x;
|
||||
[ContactSelection setSipFilter:nil];
|
||||
[ContactSelection enableEmailFilter:FALSE];
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@
|
|||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>8</string>
|
||||
<string>9</string>
|
||||
<key>ITSAppUsesNonExemptEncryption</key>
|
||||
<true/>
|
||||
<key>ITSEncryptionExportComplianceCode</key>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue