mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-12-04 15:39:34 +01:00
Show expired entries on DB unlock
* Show banner message about expired entries * Add config option and expiration offset * Only show expiry warning on first DB unlock * Default to on with 3-day offset from expiration
This commit is contained in:
committed by
Jonathan White
parent
3c824cb500
commit
6897787d8f
@@ -120,6 +120,8 @@ ApplicationSettingsWidget::ApplicationSettingsWidget(QWidget* parent)
|
||||
connect(m_generalUi->backupBeforeSaveCheckBox, SIGNAL(toggled(bool)),
|
||||
m_generalUi->backupFilePathPicker, SLOT(setEnabled(bool)));
|
||||
connect(m_generalUi->backupFilePathPicker, SIGNAL(pressed()), SLOT(selectBackupDirectory()));
|
||||
connect(m_generalUi->showExpiredEntriesOnDatabaseUnlockCheckBox, SIGNAL(toggled(bool)),
|
||||
SLOT(showExpiredEntriesOnDatabaseUnlockToggled(bool)));
|
||||
|
||||
connect(m_secUi->clearClipboardCheckBox, SIGNAL(toggled(bool)),
|
||||
m_secUi->clearClipboardSpinBox, SLOT(setEnabled(bool)));
|
||||
@@ -251,6 +253,12 @@ void ApplicationSettingsWidget::loadSettings()
|
||||
m_generalUi->checkForUpdatesIncludeBetasCheckBox->setChecked(
|
||||
config()->get(Config::GUI_CheckForUpdatesIncludeBetas).toBool());
|
||||
|
||||
m_generalUi->showExpiredEntriesOnDatabaseUnlockCheckBox->setChecked(
|
||||
config()->get(Config::GUI_ShowExpiredEntriesOnDatabaseUnlock).toBool());
|
||||
m_generalUi->showExpiredEntriesOnDatabaseUnlockOffsetSpinBox->setValue(
|
||||
config()->get(Config::GUI_ShowExpiredEntriesOnDatabaseUnlockOffsetDays).toInt());
|
||||
showExpiredEntriesOnDatabaseUnlockToggled(m_generalUi->showExpiredEntriesOnDatabaseUnlockCheckBox->isChecked());
|
||||
|
||||
m_generalUi->autoTypeAskCheckBox->setChecked(config()->get(Config::Security_AutoTypeAsk).toBool());
|
||||
|
||||
if (autoType()->isAvailable()) {
|
||||
@@ -378,6 +386,11 @@ void ApplicationSettingsWidget::saveSettings()
|
||||
config()->set(Config::GUI_CheckForUpdatesIncludeBetas,
|
||||
m_generalUi->checkForUpdatesIncludeBetasCheckBox->isChecked());
|
||||
|
||||
config()->set(Config::GUI_ShowExpiredEntriesOnDatabaseUnlock,
|
||||
m_generalUi->showExpiredEntriesOnDatabaseUnlockCheckBox->isChecked());
|
||||
config()->set(Config::GUI_ShowExpiredEntriesOnDatabaseUnlockOffsetDays,
|
||||
m_generalUi->showExpiredEntriesOnDatabaseUnlockOffsetSpinBox->value());
|
||||
|
||||
config()->set(Config::Security_AutoTypeAsk, m_generalUi->autoTypeAskCheckBox->isChecked());
|
||||
|
||||
if (autoType()->isAvailable()) {
|
||||
@@ -520,6 +533,11 @@ void ApplicationSettingsWidget::checkUpdatesToggled(bool checked)
|
||||
m_generalUi->checkForUpdatesIncludeBetasCheckBox->setEnabled(checked);
|
||||
}
|
||||
|
||||
void ApplicationSettingsWidget::showExpiredEntriesOnDatabaseUnlockToggled(bool checked)
|
||||
{
|
||||
m_generalUi->showExpiredEntriesOnDatabaseUnlockOffsetSpinBox->setEnabled(checked);
|
||||
}
|
||||
|
||||
void ApplicationSettingsWidget::selectBackupDirectory()
|
||||
{
|
||||
auto backupDirectory =
|
||||
|
||||
Reference in New Issue
Block a user