Skip to content

Commit

Permalink
Merge branch 'release/0.16.13/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
ismailgulek committed Aug 26, 2020
2 parents 576c07a + 10d4eee commit f308426
Show file tree
Hide file tree
Showing 7 changed files with 60 additions and 24 deletions.
27 changes: 27 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,30 @@
Changes in 0.16.13 (2020-08-25)
=================================================

Features:
*

Improvements:
* Introduce handleCallEvent on MXCallManager.

Bugfix:
* Some room members count are wrong after clearing the cache

API Change:
*

Translations:
*

Others:
*

Build:
*

Test:
*

Changes in 0.16.12 (2020-08-19)
=================================================

Expand Down
2 changes: 1 addition & 1 deletion MatrixSDK.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|

s.name = "MatrixSDK"
s.version = "0.16.12"
s.version = "0.16.13"
s.summary = "The iOS SDK to build apps compatible with Matrix (https://www.matrix.org)"

s.description = <<-DESC
Expand Down
2 changes: 1 addition & 1 deletion MatrixSDK/Data/MXRoomState.m
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@ - (id)copyWithZone:(NSZone *)zone

stateCopy->_members = [_members copyWithZone:zone];

stateCopy->_membersCount = _membersCount;
stateCopy->_membersCount = [_membersCount copyWithZone:zone];

stateCopy->roomAliases = [[NSMutableDictionary allocWithZone:zone] initWithDictionary:roomAliases];

Expand Down
2 changes: 1 addition & 1 deletion MatrixSDK/Data/Store/MXFileStore/MXFileStore.m
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#import "MXSDKOptions.h"
#import "MXTools.h"

static NSUInteger const kMXFileVersion = 66;
static NSUInteger const kMXFileVersion = 67;

static NSString *const kMXFileStoreFolder = @"MXFileStore";
static NSString *const kMXFileStoreMedaDataFile = @"MXFileStore";
Expand Down
2 changes: 1 addition & 1 deletion MatrixSDK/MatrixSDKVersion.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@

#import <Foundation/Foundation.h>

NSString *const MatrixSDKVersion = @"0.16.12";
NSString *const MatrixSDKVersion = @"0.16.13";
8 changes: 8 additions & 0 deletions MatrixSDK/VoIP/MXCallManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ NS_ASSUME_NONNULL_BEGIN
@class MXRoomMember;
@class MXSession;
@class MXTurnServerResponse;
@class MXEvent;

@protocol MXCallStack;

Expand Down Expand Up @@ -106,6 +107,13 @@ extern NSString *const kMXCallManagerConferenceFinished;
*/
- (void)removeCall:(MXCall *)call;

/**
Handle a call event. Ignores other types of events.
@param event The call event.
*/
- (void)handleCallEvent:(MXEvent *)event;

/**
The related matrix session.
*/
Expand Down
41 changes: 21 additions & 20 deletions MatrixSDK/VoIP/MXCallManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -80,26 +80,7 @@ - (instancetype)initWithMatrixSession:(MXSession *)mxSession andCallStack:(id<MX

if (MXTimelineDirectionForwards == direction)
{
switch (event.eventType)
{
case MXEventTypeCallInvite:
[self handleCallInvite:event];
break;

case MXEventTypeCallAnswer:
[self handleCallAnswer:event];
break;

case MXEventTypeCallHangup:
[self handleCallHangup:event];
break;

case MXEventTypeCallCandidates:
[self handleCallCandidates:event];
break;
default:
break;
}
[self handleCallEvent:event];
}
}];

Expand Down Expand Up @@ -282,6 +263,26 @@ - (void)removeCall:(MXCall *)call
[calls removeObject:call];
}

- (void)handleCallEvent:(MXEvent *)event
{
switch (event.eventType)
{
case MXEventTypeCallInvite:
[self handleCallInvite:event];
break;
case MXEventTypeCallAnswer:
[self handleCallAnswer:event];
break;
case MXEventTypeCallHangup:
[self handleCallHangup:event];
break;
case MXEventTypeCallCandidates:
[self handleCallCandidates:event];
break;
default:
break;
}
}

#pragma mark - Private methods
- (void)refreshTURNServer
Expand Down

0 comments on commit f308426

Please sign in to comment.