Feature/2099 personal state

This commit is contained in:
Arnfried Griesert
2022-06-29 11:08:57 +00:00
parent 7cdd0bf37f
commit 125e3b5362
9 changed files with 253 additions and 10 deletions
@@ -104,6 +104,12 @@ typedef BOOL (^MXKAccountOnCertificateChange)(MXKAccount *mxAccount, NSData *cer
*/
@property (nonatomic, readonly) MXPresence userPresence;
/**
The account user's status message (empty string by default).
The notification `kMXKAccountUserInfoDidChangeNotification` is posted in case of change of this property.
*/
@property (nonatomic, readonly) NSString *userStatusMessage;
/**
The account user's tint color: a unique color fixed by the user id. This tint color may be used to highlight
rooms which belong to this account's user.
@@ -282,6 +288,15 @@ typedef BOOL (^MXKAccountOnCertificateChange)(MXKAccount *mxAccount, NSData *cer
*/
- (void)setUserAvatarUrl:(NSString*)avatarUrl success:(void (^)(void))success failure:(void (^)(NSError *error))failure;
/**
Set the avatar url of the account user.
@param presence The users presence state.
@param statusMessage A custom text defined by the user that shows its current state.
@param completion Completion handler.
*/
- (void)setUserPresence:(MXPresence)presence andStatusMessage:(NSString *)statusMessage completion:(void (^)(void))completion;
/**
Update the account password.