mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-23 03:18:49 +03:00
warn about online keybackup and default to off
This commit is contained in:
parent
d97e408c98
commit
23697e28a3
1 changed files with 12 additions and 1 deletions
|
@ -124,7 +124,7 @@ UserSettings::load(std::optional<QString> profile)
|
||||||
.toBool();
|
.toBool();
|
||||||
onlyShareKeysWithVerifiedUsers_ =
|
onlyShareKeysWithVerifiedUsers_ =
|
||||||
settings.value(prefix + "user/only_share_keys_with_verified_users", false).toBool();
|
settings.value(prefix + "user/only_share_keys_with_verified_users", false).toBool();
|
||||||
useOnlineKeyBackup_ = settings.value(prefix + "user/online_key_backup", true).toBool();
|
useOnlineKeyBackup_ = settings.value(prefix + "user/online_key_backup", false).toBool();
|
||||||
|
|
||||||
disableCertificateValidation_ =
|
disableCertificateValidation_ =
|
||||||
settings.value("disable_certificate_validation", false).toBool();
|
settings.value("disable_certificate_validation", false).toBool();
|
||||||
|
@ -1228,6 +1228,17 @@ UserSettingsPage::UserSettingsPage(QSharedPointer<UserSettings> settings, QWidge
|
||||||
});
|
});
|
||||||
|
|
||||||
connect(useOnlineKeyBackup_, &Toggle::toggled, this, [this](bool enabled) {
|
connect(useOnlineKeyBackup_, &Toggle::toggled, this, [this](bool enabled) {
|
||||||
|
if (enabled) {
|
||||||
|
if (QMessageBox::question(
|
||||||
|
this,
|
||||||
|
tr("Enable online key backup"),
|
||||||
|
tr("The Nheko authors recommend not enabling online key backup until "
|
||||||
|
"symmetric online key backup is available. Enable anyway?")) !=
|
||||||
|
QMessageBox::StandardButton::NoButton) {
|
||||||
|
useOnlineKeyBackup_->setState(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
settings_->setUseOnlineKeyBackup(enabled);
|
settings_->setUseOnlineKeyBackup(enabled);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue