Rename profile as userAvatarAndName

This commit is contained in:
Arnaud Ringenbach
2022-03-04 15:48:59 +01:00
committed by aringenbach
parent fb95e6fd78
commit cfeae5bc64
8 changed files with 30 additions and 24 deletions
@@ -160,7 +160,7 @@ typedef NS_ENUM(NSUInteger, LABS_ENABLE)
LABS_ENABLE_RINGING_FOR_GROUP_CALLS_INDEX = 0,
LABS_ENABLE_THREADS_INDEX,
LABS_ENABLE_MESSAGE_BUBBLES_INDEX,
LABS_USE_ONLY_LATEST_PROFILES_INDEX
LABS_USE_ONLY_LATEST_USER_AVATAR_AND_NAME_INDEX
};
typedef NS_ENUM(NSUInteger, SECURITY)
@@ -573,7 +573,7 @@ TableViewSectionsDelegate>
[sectionLabs addRowWithTag:LABS_ENABLE_RINGING_FOR_GROUP_CALLS_INDEX];
[sectionLabs addRowWithTag:LABS_ENABLE_THREADS_INDEX];
[sectionLabs addRowWithTag:LABS_ENABLE_MESSAGE_BUBBLES_INDEX];
[sectionLabs addRowWithTag:LABS_USE_ONLY_LATEST_PROFILES_INDEX];
[sectionLabs addRowWithTag:LABS_USE_ONLY_LATEST_USER_AVATAR_AND_NAME_INDEX];
sectionLabs.headerTitle = [VectorL10n settingsLabs];
if (sectionLabs.hasAnyRows)
{
@@ -2464,15 +2464,15 @@ TableViewSectionsDelegate>
{
cell = [self buildMessageBubblesCellForTableView:tableView atIndexPath:indexPath];
}
else if (row == LABS_USE_ONLY_LATEST_PROFILES_INDEX)
else if (row == LABS_USE_ONLY_LATEST_USER_AVATAR_AND_NAME_INDEX)
{
MXKTableViewCellWithLabelAndSwitch *labelAndSwitchCell = [self getLabelAndSwitchCell:tableView forIndexPath:indexPath];
labelAndSwitchCell.mxkLabel.text = VectorL10n.settingsLabsUseOnlyLatestProfiles;
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.roomScreenUseOnlyLatestProfiles;
labelAndSwitchCell.mxkLabel.text = VectorL10n.settingsLabsUseOnlyLatestUserAvatarAndName;
labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.roomScreenUseOnlyLatestUserAvatarAndName;
labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor;
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleUseOnlyLatestProfiles:) forControlEvents:UIControlEventTouchUpInside];
[labelAndSwitchCell.mxkSwitch addTarget:self action:@selector(toggleUseOnlyLatestUserAvatarAndName:) forControlEvents:UIControlEventTouchUpInside];
cell = labelAndSwitchCell;
}
@@ -3258,9 +3258,9 @@ TableViewSectionsDelegate>
}
}
- (void)toggleUseOnlyLatestProfiles:(UISwitch *)sender
- (void)toggleUseOnlyLatestUserAvatarAndName:(UISwitch *)sender
{
RiotSettings.shared.roomScreenUseOnlyLatestProfiles = sender.isOn;
RiotSettings.shared.roomScreenUseOnlyLatestUserAvatarAndName = sender.isOn;
}
- (void)markAllAsRead:(id)sender