mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-21 00:52:43 +02:00
Feature/2099 personal state
This commit is contained in:
@@ -79,6 +79,7 @@ typedef NS_ENUM(NSUInteger, USER_SETTINGS_INDEX)
|
||||
{
|
||||
USER_SETTINGS_PROFILE_PICTURE_INDEX = 0,
|
||||
USER_SETTINGS_DISPLAYNAME_INDEX,
|
||||
USER_SETTINGS_PERSONAL_STATE_INDEX,
|
||||
USER_SETTINGS_CHANGE_PASSWORD_INDEX,
|
||||
USER_SETTINGS_FIRST_NAME_INDEX,
|
||||
USER_SETTINGS_SURNAME_INDEX,
|
||||
@@ -402,6 +403,7 @@ ThreadsBetaCoordinatorBridgePresenterDelegate>
|
||||
Section *sectionUserSettings = [Section sectionWithTag:SECTION_TAG_USER_SETTINGS];
|
||||
[sectionUserSettings addRowWithTag:USER_SETTINGS_PROFILE_PICTURE_INDEX];
|
||||
[sectionUserSettings addRowWithTag:USER_SETTINGS_DISPLAYNAME_INDEX];
|
||||
[sectionUserSettings addRowWithTag:USER_SETTINGS_PERSONAL_STATE_INDEX];
|
||||
if (RiotSettings.shared.settingsScreenShowChangePassword)
|
||||
{
|
||||
[sectionUserSettings addRowWithTag:USER_SETTINGS_CHANGE_PASSWORD_INDEX];
|
||||
@@ -1992,6 +1994,17 @@ ThreadsBetaCoordinatorBridgePresenterDelegate>
|
||||
|
||||
cell = displaynameCell;
|
||||
}
|
||||
else if (row == USER_SETTINGS_PERSONAL_STATE_INDEX)
|
||||
{
|
||||
cell = [tableView dequeueReusableCellWithIdentifier:kSettingsViewControllerPhoneBookCountryCellId];
|
||||
if (!cell)
|
||||
{
|
||||
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kSettingsViewControllerPhoneBookCountryCellId];
|
||||
}
|
||||
|
||||
cell.textLabel.text = [VectorL10n bwiEditPersonalStateMyState];
|
||||
cell.detailTextLabel.text = account.userStatusMessage;
|
||||
}
|
||||
else if (row == USER_SETTINGS_FIRST_NAME_INDEX)
|
||||
{
|
||||
MXKTableViewCellWithLabelAndTextField *firstCell = [self getLabelAndTextFieldCell:tableView forIndexPath:indexPath];
|
||||
@@ -3224,6 +3237,10 @@ ThreadsBetaCoordinatorBridgePresenterDelegate>
|
||||
{
|
||||
[self onProfileAvatarTap:nil];
|
||||
}
|
||||
if (row == USER_SETTINGS_PERSONAL_STATE_INDEX)
|
||||
{
|
||||
[self showPersonalStateSettings];
|
||||
}
|
||||
else if (row == USER_SETTINGS_CHANGE_PASSWORD_INDEX)
|
||||
{
|
||||
[self displayPasswordAlert];
|
||||
@@ -4390,6 +4407,14 @@ ThreadsBetaCoordinatorBridgePresenterDelegate>
|
||||
}
|
||||
}
|
||||
|
||||
- (void)showPersonalStateSettings
|
||||
{
|
||||
if (@available(iOS 14.0, *)) {
|
||||
UIViewController *personalStateViewController = [PersonalStateViewController makeViewControllerWithSession:self.mainSession];
|
||||
[self pushViewController:personalStateViewController];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)showNotificationTimesSettings
|
||||
{
|
||||
if (@available(iOS 14.0, *)) {
|
||||
|
||||
Reference in New Issue
Block a user