mirror of
https://git.jami.net/savoirfairelinux/jami-client-qt.git
synced 2025-09-10 12:03:18 +02:00
profile: minor fixes
+ ModalTextEdit should not change its editMode if isPersistent, else some editions can be missed. + Do not emit profileChanged when the client changes only the alias, as it's updated by the account's config. Change-Id: I3381b7494366fcd2d6a8504f0dcf18b622dc1701
This commit is contained in:
parent
9e05e3e186
commit
8716154b58
2 changed files with 8 additions and 9 deletions
|
@ -99,7 +99,7 @@ Loader {
|
|||
inputIsValid: root.inputIsValid
|
||||
onFocusChanged: {
|
||||
if (!focus && root.editMode) {
|
||||
root.editMode = false
|
||||
root.editMode = isPersistent
|
||||
root.accepted()
|
||||
}
|
||||
activeChanged(root.editMode)
|
||||
|
|
|
@ -270,11 +270,12 @@ AccountModel::setAccountConfig(const QString& accountId,
|
|||
finalCred.append(credMap);
|
||||
}
|
||||
|
||||
VectorMapStringString oldCredentials = ConfigurationManager::instance().getCredentials(accountId);
|
||||
if (oldCredentials.empty() || finalCred.empty() ||
|
||||
oldCredentials[0][ConfProperties::PASSWORD] != finalCred[0][ConfProperties::PASSWORD] ||
|
||||
oldCredentials[0][ConfProperties::REALM] != finalCred[0][ConfProperties::REALM] ||
|
||||
oldCredentials[0][ConfProperties::USERNAME] != finalCred[0][ConfProperties::USERNAME])
|
||||
VectorMapStringString oldCredentials = ConfigurationManager::instance().getCredentials(
|
||||
accountId);
|
||||
if (oldCredentials.empty() || finalCred.empty()
|
||||
|| oldCredentials[0][ConfProperties::PASSWORD] != finalCred[0][ConfProperties::PASSWORD]
|
||||
|| oldCredentials[0][ConfProperties::REALM] != finalCred[0][ConfProperties::REALM]
|
||||
|| oldCredentials[0][ConfProperties::USERNAME] != finalCred[0][ConfProperties::USERNAME])
|
||||
ConfigurationManager::instance().setCredentials(accountId, finalCred);
|
||||
details[ConfProperties::USERNAME] = confProperties.username;
|
||||
accountInfo.confProperties.credentials.swap(credentialsVec);
|
||||
|
@ -297,8 +298,6 @@ AccountModel::setAlias(const QString& accountId, const QString& alias)
|
|||
accountInfo.profileInfo.alias = alias;
|
||||
|
||||
authority::storage::createOrUpdateProfile(accountInfo.id, accountInfo.profileInfo);
|
||||
|
||||
Q_EMIT profileUpdated(accountId);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -823,7 +822,7 @@ account::Info::fromDetails(const MapStringString& details)
|
|||
profileInfo.alias = details[ConfProperties::DISPLAYNAME];
|
||||
enabled = toBool(details[ConfProperties::ENABLED]);
|
||||
status = lrc::api::account::to_status(
|
||||
volatileDetails[libjami::Account::ConfProperties::Registration::STATUS]);
|
||||
volatileDetails[libjami::Account::ConfProperties::Registration::STATUS]);
|
||||
confProperties.mailbox = details[ConfProperties::MAILBOX];
|
||||
confProperties.dtmfType = details[ConfProperties::DTMF_TYPE];
|
||||
confProperties.autoAnswer = toBool(details[ConfProperties::AUTOANSWER]);
|
||||
|
|
Loading…
Add table
Reference in a new issue