Merge branch 'release/1.8.1/master'

This commit is contained in:
Stefan Ceriu
2022-02-16 12:45:01 +02:00
11 changed files with 88 additions and 33 deletions

View File

@@ -1,3 +1,15 @@
## Changes in 1.8.1 (2022-02-16)
🙌 Improvements
- Upgrade MatrixSDK version ([v0.22.1](https://github.com/matrix-org/matrix-ios-sdk/releases/tag/v0.22.1)).
🐛 Bugfixes
- Settings: Fix a bug where tapping a toggle could change multiple settings. ([#5463](https://github.com/vector-im/element-ios/issues/5463))
- Fix for images sometimes being sent unencrypted inside an encrypted room. ([#5564](https://github.com/vector-im/element-ios/issues/5564))
## Changes in 1.8.0 (2022-02-09)
✨ Features

View File

@@ -15,5 +15,5 @@
//
// Version
MARKETING_VERSION = 1.8.0
CURRENT_PROJECT_VERSION = 1.8.0
MARKETING_VERSION = 1.8.1
CURRENT_PROJECT_VERSION = 1.8.1

View File

@@ -13,7 +13,7 @@ use_frameworks!
# - `{ :specHash => {sdk spec hash}` to depend on specific pod options (:git => …, :podspec => …) for MatrixSDK repo. Used by Fastfile during CI
#
# Warning: our internal tooling depends on the name of this variable name, so be sure not to change it
$matrixSDKVersion = '= 0.22.0'
$matrixSDKVersion = '= 0.22.1'
# $matrixSDKVersion = :local
# $matrixSDKVersion = { :branch => 'develop'}
# $matrixSDKVersion = { :specHash => { git: 'https://git.io/fork123', branch: 'fix' } }

View File

@@ -57,16 +57,16 @@ PODS:
- LoggerAPI (1.9.200):
- Logging (~> 1.1)
- Logging (1.4.0)
- MatrixSDK (0.22.0):
- MatrixSDK/Core (= 0.22.0)
- MatrixSDK/Core (0.22.0):
- MatrixSDK (0.22.1):
- MatrixSDK/Core (= 0.22.1)
- MatrixSDK/Core (0.22.1):
- AFNetworking (~> 4.0.0)
- GZIP (~> 1.3.0)
- libbase58 (~> 0.1.4)
- OLMKit (~> 3.2.5)
- Realm (= 10.16.0)
- SwiftyBeaver (= 1.9.5)
- MatrixSDK/JingleCallStack (0.22.0):
- MatrixSDK/JingleCallStack (0.22.1):
- JitsiMeetSDK (= 3.10.2)
- MatrixSDK/Core
- OLMKit (3.2.5):
@@ -117,8 +117,8 @@ DEPENDENCIES:
- KeychainAccess (~> 4.2.2)
- KTCenterFlowLayout (~> 1.3.1)
- libPhoneNumber-iOS (~> 0.9.13)
- MatrixSDK (= 0.22.0)
- MatrixSDK/JingleCallStack (= 0.22.0)
- MatrixSDK (= 0.22.1)
- MatrixSDK/JingleCallStack (= 0.22.1)
- OLMKit
- PostHog (~> 1.4.4)
- ReadMoreTextView (~> 3.0.1)
@@ -212,7 +212,7 @@ SPEC CHECKSUMS:
libPhoneNumber-iOS: 0a32a9525cf8744fe02c5206eb30d571e38f7d75
LoggerAPI: ad9c4a6f1e32f518fdb43a1347ac14d765ab5e3d
Logging: beeb016c9c80cf77042d62e83495816847ef108b
MatrixSDK: 21201cd007145d96beff24cc7f9727ced497c3fd
MatrixSDK: 12c1a56e037f629e493cbcd615fd13cfc58cee3a
OLMKit: 9fb4799c4a044dd2c06bda31ec31a12191ad30b5
PostHog: 4b6321b521569092d4ef3a02238d9435dbaeb99f
ReadMoreTextView: 19147adf93abce6d7271e14031a00303fe28720d
@@ -229,6 +229,6 @@ SPEC CHECKSUMS:
zxcvbn-ios: fef98b7c80f1512ff0eec47ac1fa399fc00f7e3c
ZXingObjC: fdbb269f25dd2032da343e06f10224d62f537bdb
PODFILE CHECKSUM: 2a13c9d4f4894152af066c746582fde2e731cbff
PODFILE CHECKSUM: ae70a46e98aae87f130ad3d246711fc6b6ae7286
COCOAPODS: 1.11.2

View File

@@ -438,10 +438,17 @@ typedef NS_ENUM(NSUInteger, MXKRoomViewControllerJoinRoomResult) {
- (void)setBubbleTableViewContentOffset:(CGPoint)contentOffset animated:(BOOL)animated;
/**
Handle typing notification.
Sends a typing notification with the specified timeout.
@param typing Flag indicating whether the user is typing or not.
@param notificationTimeoutMS The length of time the typing notification is valid for
*/
- (void)handleTypingNotification:(BOOL)typing;
- (void)sendTypingNotification:(BOOL)typing timeout:(NSUInteger)notificationTimeoutMS;
/**
Share encryption keys in this room.
*/
- (void)shareEncryptionKeys;
@end

View File

@@ -3299,7 +3299,7 @@
roomDataSource.partialTextMessage = inputToolbarView.textMessage;
}
[self handleTypingNotification:typing];
[self handleTypingState:typing];
}
- (void)roomInputToolbarView:(MXKRoomInputToolbarView*)toolbarView heightDidChanged:(CGFloat)height completion:(void (^)(BOOL finished))completion
@@ -3420,7 +3420,7 @@
}
# pragma mark - Typing notification
- (void)handleTypingNotification:(BOOL)typing
- (void)handleTypingState:(BOOL)typing
{
NSUInteger notificationTimeoutMS = -1;
if (typing)
@@ -3482,6 +3482,11 @@
lastTypingDate = nil;
}
[self sendTypingNotification:typing timeout:notificationTimeoutMS];
}
- (void)sendTypingNotification:(BOOL)typing timeout:(NSUInteger)notificationTimeoutMS
{
MXWeakify(self);
// Send typing notification to server
@@ -3512,7 +3517,7 @@
// Check whether a new typing event has been observed
BOOL typing = (lastTypingDate != nil);
// Post a new typing notification
[self handleTypingNotification:typing];
[self handleTypingState:typing];
}

View File

@@ -4564,6 +4564,15 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
[self.userSuggestionCoordinator processTextMessage:toolbarView.textMessage];
}
- (void)roomInputToolbarViewDidOpenActionMenu:(MXKRoomInputToolbarView*)toolbarView
{
// Consider opening the action menu as beginning to type and share encryption keys if requested.
if ([MXKAppSettings standardAppSettings].outboundGroupSessionKeyPreSharingStrategy == MXKKeyPreSharingWhenTyping)
{
[self shareEncryptionKeys];
}
}
#pragma mark - MXKRoomMemberDetailsViewControllerDelegate
- (void)roomMemberDetailsViewController:(MXKRoomMemberDetailsViewController *)roomMemberDetailsViewController startChatWithMemberId:(NSString *)matrixId completion:(void (^)(void))completion

View File

@@ -47,6 +47,13 @@ typedef enum : NSUInteger
*/
- (void)roomInputToolbarViewDidChangeTextMessage:(MXKRoomInputToolbarView*)toolbarView;
/**
Inform the delegate that the action menu was opened.
@param toolbarView the room input toolbar view
*/
- (void)roomInputToolbarViewDidOpenActionMenu:(MXKRoomInputToolbarView*)toolbarView;
@end
/**

View File

@@ -429,6 +429,7 @@ static const NSTimeInterval kActionMenuComposerHeightAnimationDuration = .3;
if (_actionMenuOpened) {
self.actionsBar.hidden = NO;
[self.actionsBar animateWithShowIn:_actionMenuOpened completion:nil];
[self.delegate roomInputToolbarViewDidOpenActionMenu:self];
}
else
{

View File

@@ -158,7 +158,8 @@ typedef NS_ENUM(NSUInteger, ABOUT)
typedef NS_ENUM(NSUInteger, LABS_ENABLE)
{
LABS_ENABLE_RINGING_FOR_GROUP_CALLS_INDEX = 0,
LABS_ENABLE_THREADS_INDEX
LABS_ENABLE_THREADS_INDEX,
LABS_ENABLE_MESSAGE_BUBBLES_INDEX
};
typedef NS_ENUM(NSUInteger, SECURITY)
@@ -508,7 +509,9 @@ TableViewSectionsDelegate>
if (BuildSettings.roomScreenAllowTimelineStyleConfiguration)
{
[sectionUserInterface addRowWithTag:USER_INTERFACE_TIMELINE_STYLE_INDEX];
// NOTE: Message bubbles are under labs section atm
// [sectionUserInterface addRowWithTag:USER_INTERFACE_TIMELINE_STYLE_INDEX];
}
[tmpSections addObject: sectionUserInterface];
@@ -566,6 +569,7 @@ TableViewSectionsDelegate>
Section *sectionLabs = [Section sectionWithTag:SECTION_TAG_LABS];
[sectionLabs addRowWithTag:LABS_ENABLE_RINGING_FOR_GROUP_CALLS_INDEX];
[sectionLabs addRowWithTag:LABS_ENABLE_THREADS_INDEX];
[sectionLabs addRowWithTag:LABS_ENABLE_MESSAGE_BUBBLES_INDEX];
sectionLabs.headerTitle = [VectorL10n settingsLabs];
if (sectionLabs.hasAnyRows)
{
@@ -1469,6 +1473,21 @@ TableViewSectionsDelegate>
return [footerText copy];
}
- (UITableViewCell *)buildMessageBubblesCellForTableView:(UITableView*)tableView
atIndexPath:(NSIndexPath*)indexPath
{
MXKTableViewCellWithLabelAndSwitch* labelAndSwitchCell = [self getLabelAndSwitchCell:tableView forIndexPath:indexPath];
labelAndSwitchCell.mxkLabel.text = [VectorL10n settingsEnableRoomMessageBubbles];
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.roomScreenEnableMessageBubbles;
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
labelAndSwitchCell.mxkSwitch.enabled = YES;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableRoomMessageBubbles:) forControlEvents:UIControlEventTouchUpInside];
return labelAndSwitchCell;
}
#pragma mark - 3Pid Add
- (void)showAuthenticationIfNeededForAdding:(MX3PIDMedium)medium withSession:(MXSession*)session completion:(void (^)(NSDictionary* authParams))completion
@@ -1976,7 +1995,7 @@ TableViewSectionsDelegate>
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
labelAndSwitchCell.mxkSwitch.enabled = YES;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableURLPreviews:) forControlEvents:UIControlEventValueChanged];
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableURLPreviews:) forControlEvents:UIControlEventTouchUpInside];
cell = labelAndSwitchCell;
}
@@ -2206,16 +2225,7 @@ TableViewSectionsDelegate>
}
else if (row == USER_INTERFACE_TIMELINE_STYLE_INDEX)
{
MXKTableViewCellWithLabelAndSwitch* labelAndSwitchCell = [self getLabelAndSwitchCell:tableView forIndexPath:indexPath];
labelAndSwitchCell.mxkLabel.text = [VectorL10n settingsEnableRoomMessageBubbles];
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.roomScreenEnableMessageBubbles;
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
labelAndSwitchCell.mxkSwitch.enabled = YES;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableRoomMessageBubbles:) forControlEvents:UIControlEventTouchUpInside];
cell = labelAndSwitchCell;
cell = [self buildMessageBubblesCellForTableView:tableView atIndexPath:indexPath];
}
}
else if (section == SECTION_TAG_IGNORED_USERS)
@@ -2430,7 +2440,7 @@ TableViewSectionsDelegate>
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.enableRingingForGroupCalls;
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableRingingForGroupCalls:) forControlEvents:UIControlEventValueChanged];
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableRingingForGroupCalls:) forControlEvents:UIControlEventTouchUpInside];
cell = labelAndSwitchCell;
}
@@ -2442,10 +2452,14 @@ TableViewSectionsDelegate>
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.enableThreads;
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableThreads:) forControlEvents:UIControlEventValueChanged];
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleEnableThreads:) forControlEvents:UIControlEventTouchUpInside];
cell = labelAndSwitchCell;
}
else if (row == LABS_ENABLE_MESSAGE_BUBBLES_INDEX)
{
cell = [self buildMessageBubblesCellForTableView:tableView atIndexPath:indexPath];
}
}
else if (section == SECTION_TAG_FLAIR)
{

View File

@@ -70,8 +70,8 @@ class ThreadViewController: RoomViewController {
super.onButtonPressed(sender)
}
override func handleTypingNotification(_ typing: Bool) {
// no-op
override func sendTypingNotification(_ typing: Bool, timeout notificationTimeoutMS: UInt) {
// no-op
}
private func showThreadActions() {