mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-25 07:19:42 -05:00
Add Import/Export to application settings
* Closes #9452 - add import/export buttons to application settings * Fixes #11120 - duplicate both menubar and toolbar visibility settings into the application settings * Fixes #8561 - improve placement of various settings between General and Security pages * Improve tool tip for backup database setting * Improve wording of various settings
This commit is contained in:
parent
ba0fc3b886
commit
684122c9a9
@ -219,18 +219,30 @@
|
||||
<source>You must restart the application to set the new language. Would you like to restart now?</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Reset Settings?</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Are you sure you want to reset all general and security settings to default?</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Select backup storage directory</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Confirm Reset</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Are you sure you want to reset all settings to default?</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Import KeePassXC Settings</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Failed to import settings from %1, not a valid settings file.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Export KeePassXC Settings</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>ApplicationSettingsWidgetGeneral</name>
|
||||
@ -306,22 +318,10 @@
|
||||
<source>Backup database file before saving</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Backup destination</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Specifies the database backup file location. Occurrences of "{DB_FILENAME}" are replaced with the filename of the saved database without extension. {TIME:<format>} is replaced with the backup time, see https://doc.qt.io/qt-5/qdatetime.html#toString. <format> defaults to format string "dd_MM_yyyy_hh-mm-ss".</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>{DB_FILENAME}.old.kdbx</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Choose...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Use alternative saving method (may solve problems with Dropbox, Google Drive, GVFS, etc.)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
@ -501,6 +501,46 @@
|
||||
<comment>number of days warning for password expiration</comment>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Destination format:</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source><html><head/><body><p><span style=" font-weight:600;">{DB_FILENAME}</span> is replaced with the filename of the saved database without extension</p><p><span style=" font-weight:600;">{TIME:&lt;format&gt;}</span> is replaced with the specified time format (default: dd_MM_yyyy_hh-mm-ss)</p><p>See the User Guide for more details</p></body></html></source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Choose folder...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Show confirmation before moving entries to recycle bin</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Copy data on double clicking field in entry view</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Show toolbar</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Show the menu bar by pressing the Alt key</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Show menubar</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Import settings…</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Export settings…</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>ApplicationSettingsWidgetSecurity</name>
|
||||
@ -566,18 +606,6 @@
|
||||
<source>Hide passwords in the entry preview panel</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Hide entry notes by default</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Move entries to recycle bin without confirmation</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Enable double click to copy the username/password entry columns</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Privacy</source>
|
||||
<translation type="unfinished"></translation>
|
||||
@ -594,6 +622,14 @@
|
||||
<source>Lock databases when switching user</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Lock Options</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Hide notes in the entry preview panel</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AutoType</name>
|
||||
|
@ -302,6 +302,45 @@ void Config::resetToDefaults()
|
||||
}
|
||||
}
|
||||
|
||||
bool Config::importSettings(const QString& fileName)
|
||||
{
|
||||
// Ensure file is valid ini with values
|
||||
QSettings settings(fileName, QSettings::IniFormat);
|
||||
if (settings.status() != QSettings::NoError || settings.allKeys().isEmpty()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Only import valid roaming settings
|
||||
auto isValidSetting = [](const QString& key) {
|
||||
for (const auto& value : configStrings.values()) {
|
||||
if (value.type == ConfigType::Roaming && value.name == key) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
};
|
||||
|
||||
// Clear existing settings and set valid items
|
||||
m_settings->clear();
|
||||
for (const auto& key : settings.allKeys()) {
|
||||
if (isValidSetting(key)) {
|
||||
m_settings->setValue(key, settings.value(key));
|
||||
}
|
||||
}
|
||||
|
||||
sync();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void Config::exportSettings(const QString& fileName) const
|
||||
{
|
||||
QSettings settings(fileName, QSettings::IniFormat);
|
||||
for (const auto& key : m_settings->allKeys()) {
|
||||
settings.setValue(key, m_settings->value(key));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Map of configuration file settings that are either deprecated, or have
|
||||
* had their name changed to their new config enum values.
|
||||
|
@ -217,6 +217,9 @@ public:
|
||||
void sync();
|
||||
void resetToDefaults();
|
||||
|
||||
bool importSettings(const QString& fileName);
|
||||
void exportSettings(const QString& fileName) const;
|
||||
|
||||
QList<ShortcutEntry> getShortcuts() const;
|
||||
void setShortcuts(const QList<ShortcutEntry>& shortcuts);
|
||||
|
||||
|
@ -117,6 +117,8 @@ ApplicationSettingsWidget::ApplicationSettingsWidget(QWidget* parent)
|
||||
connect(m_generalUi->systrayShowCheckBox, SIGNAL(toggled(bool)), SLOT(systrayToggled(bool)));
|
||||
connect(m_generalUi->rememberLastDatabasesCheckBox, SIGNAL(toggled(bool)), SLOT(rememberDatabasesToggled(bool)));
|
||||
connect(m_generalUi->resetSettingsButton, SIGNAL(clicked()), SLOT(resetSettings()));
|
||||
connect(m_generalUi->importSettingsButton, SIGNAL(clicked()), SLOT(importSettings()));
|
||||
connect(m_generalUi->exportSettingsButton, SIGNAL(clicked()), SLOT(exportSettings()));
|
||||
connect(m_generalUi->useAlternativeSaveCheckBox, SIGNAL(toggled(bool)),
|
||||
m_generalUi->alternativeSaveComboBox, SLOT(setEnabled(bool)));
|
||||
|
||||
@ -233,6 +235,10 @@ void ApplicationSettingsWidget::loadSettings()
|
||||
m_generalUi->autoTypeEntryURLMatchCheckBox->setChecked(config()->get(Config::AutoTypeEntryURLMatch).toBool());
|
||||
m_generalUi->autoTypeHideExpiredEntryCheckBox->setChecked(config()->get(Config::AutoTypeHideExpiredEntry).toBool());
|
||||
m_generalUi->faviconTimeoutSpinBox->setValue(config()->get(Config::FaviconDownloadTimeout).toInt());
|
||||
m_generalUi->ConfirmMoveEntryToRecycleBinCheckBox->setChecked(
|
||||
!config()->get(Config::Security_NoConfirmMoveEntryToRecycleBin).toBool());
|
||||
m_generalUi->EnableCopyOnDoubleClickCheckBox->setChecked(
|
||||
config()->get(Config::Security_EnableCopyOnDoubleClick).toBool());
|
||||
|
||||
m_generalUi->languageComboBox->clear();
|
||||
QList<QPair<QString, QString>> languages = Translator::availableLanguages();
|
||||
@ -244,6 +250,8 @@ void ApplicationSettingsWidget::loadSettings()
|
||||
m_generalUi->languageComboBox->setCurrentIndex(defaultIndex);
|
||||
}
|
||||
|
||||
m_generalUi->menubarShowCheckBox->setChecked(!config()->get(Config::GUI_HideMenubar).toBool());
|
||||
m_generalUi->toolbarShowCheckBox->setChecked(!config()->get(Config::GUI_HideToolbar).toBool());
|
||||
m_generalUi->toolbarMovableCheckBox->setChecked(config()->get(Config::GUI_MovableToolbar).toBool());
|
||||
m_generalUi->monospaceNotesCheckBox->setChecked(config()->get(Config::GUI_MonospaceNotes).toBool());
|
||||
m_generalUi->colorPasswordsCheckBox->setChecked(config()->get(Config::GUI_ColorPasswords).toBool());
|
||||
@ -332,10 +340,6 @@ void ApplicationSettingsWidget::loadSettings()
|
||||
config()->get(Config::Security_HidePasswordPreviewPanel).toBool());
|
||||
m_secUi->hideTotpCheckBox->setChecked(config()->get(Config::Security_HideTotpPreviewPanel).toBool());
|
||||
m_secUi->hideNotesCheckBox->setChecked(config()->get(Config::Security_HideNotes).toBool());
|
||||
m_secUi->NoConfirmMoveEntryToRecycleBinCheckBox->setChecked(
|
||||
config()->get(Config::Security_NoConfirmMoveEntryToRecycleBin).toBool());
|
||||
m_secUi->EnableCopyOnDoubleClickCheckBox->setChecked(
|
||||
config()->get(Config::Security_EnableCopyOnDoubleClick).toBool());
|
||||
|
||||
m_secUi->quickUnlockCheckBox->setEnabled(getQuickUnlock()->isAvailable());
|
||||
m_secUi->quickUnlockCheckBox->setChecked(config()->get(Config::Security_QuickUnlock).toBool());
|
||||
@ -386,6 +390,9 @@ void ApplicationSettingsWidget::saveSettings()
|
||||
config()->set(Config::AutoTypeEntryURLMatch, m_generalUi->autoTypeEntryURLMatchCheckBox->isChecked());
|
||||
config()->set(Config::AutoTypeHideExpiredEntry, m_generalUi->autoTypeHideExpiredEntryCheckBox->isChecked());
|
||||
config()->set(Config::FaviconDownloadTimeout, m_generalUi->faviconTimeoutSpinBox->value());
|
||||
config()->set(Config::Security_NoConfirmMoveEntryToRecycleBin,
|
||||
!m_generalUi->ConfirmMoveEntryToRecycleBinCheckBox->isChecked());
|
||||
config()->set(Config::Security_EnableCopyOnDoubleClick, m_generalUi->EnableCopyOnDoubleClickCheckBox->isChecked());
|
||||
|
||||
auto language = m_generalUi->languageComboBox->currentData().toString();
|
||||
if (config()->get(Config::GUI_Language) != language) {
|
||||
@ -396,6 +403,8 @@ void ApplicationSettingsWidget::saveSettings()
|
||||
}
|
||||
config()->set(Config::GUI_Language, language);
|
||||
|
||||
config()->set(Config::GUI_HideMenubar, !m_generalUi->menubarShowCheckBox->isChecked());
|
||||
config()->set(Config::GUI_HideToolbar, !m_generalUi->toolbarShowCheckBox->isChecked());
|
||||
config()->set(Config::GUI_MovableToolbar, m_generalUi->toolbarMovableCheckBox->isChecked());
|
||||
config()->set(Config::GUI_MonospaceNotes, m_generalUi->monospaceNotesCheckBox->isChecked());
|
||||
config()->set(Config::GUI_ColorPasswords, m_generalUi->colorPasswordsCheckBox->isChecked());
|
||||
@ -446,9 +455,6 @@ void ApplicationSettingsWidget::saveSettings()
|
||||
config()->set(Config::Security_HidePasswordPreviewPanel, m_secUi->passwordPreviewCleartextCheckBox->isChecked());
|
||||
config()->set(Config::Security_HideTotpPreviewPanel, m_secUi->hideTotpCheckBox->isChecked());
|
||||
config()->set(Config::Security_HideNotes, m_secUi->hideNotesCheckBox->isChecked());
|
||||
config()->set(Config::Security_NoConfirmMoveEntryToRecycleBin,
|
||||
m_secUi->NoConfirmMoveEntryToRecycleBinCheckBox->isChecked());
|
||||
config()->set(Config::Security_EnableCopyOnDoubleClick, m_secUi->EnableCopyOnDoubleClickCheckBox->isChecked());
|
||||
|
||||
if (m_secUi->quickUnlockCheckBox->isEnabled()) {
|
||||
config()->set(Config::Security_QuickUnlock, m_secUi->quickUnlockCheckBox->isChecked());
|
||||
@ -476,8 +482,8 @@ void ApplicationSettingsWidget::resetSettings()
|
||||
{
|
||||
// Confirm reset
|
||||
auto ans = MessageBox::question(this,
|
||||
tr("Reset Settings?"),
|
||||
tr("Are you sure you want to reset all general and security settings to default?"),
|
||||
tr("Confirm Reset"),
|
||||
tr("Are you sure you want to reset all settings to default?"),
|
||||
MessageBox::Reset | MessageBox::Cancel,
|
||||
MessageBox::Cancel);
|
||||
if (ans == MessageBox::Cancel) {
|
||||
@ -512,6 +518,33 @@ void ApplicationSettingsWidget::resetSettings()
|
||||
emit settingsReset();
|
||||
}
|
||||
|
||||
void ApplicationSettingsWidget::importSettings()
|
||||
{
|
||||
auto file = fileDialog()->getOpenFileName(this, tr("Import KeePassXC Settings"), {}, "*.ini");
|
||||
if (file.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!config()->importSettings(file)) {
|
||||
showMessage(tr("Failed to import settings from %1, not a valid settings file.").arg(file),
|
||||
MessageWidget::Error);
|
||||
return;
|
||||
}
|
||||
|
||||
loadSettings();
|
||||
emit settingsReset();
|
||||
}
|
||||
|
||||
void ApplicationSettingsWidget::exportSettings()
|
||||
{
|
||||
auto file = fileDialog()->getSaveFileName(this, tr("Export KeePassXC Settings"), {}, "*.ini");
|
||||
if (file.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
config()->exportSettings(file);
|
||||
}
|
||||
|
||||
void ApplicationSettingsWidget::reject()
|
||||
{
|
||||
// register the old key again as it might have changed
|
||||
|
@ -54,6 +54,8 @@ signals:
|
||||
private slots:
|
||||
void saveSettings();
|
||||
void resetSettings();
|
||||
void importSettings();
|
||||
void exportSettings();
|
||||
void reject();
|
||||
void autoSaveToggled(bool checked);
|
||||
void hideWindowOnCopyCheckBoxToggled(bool checked);
|
||||
|
@ -58,8 +58,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>566</width>
|
||||
<height>975</height>
|
||||
<width>568</width>
|
||||
<height>1153</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_8">
|
||||
@ -268,31 +268,25 @@
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QGridLayout" name="showExpiredEntriesSubLayout">
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetMaximumSize</enum>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<item row="0" column="0">
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetMaximumSize</enum>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="showExpiredEntriesOnDatabaseUnlockCheckBox">
|
||||
<property name="text">
|
||||
<string>On database unlock, show entries that will expire within</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<item>
|
||||
<widget class="QSpinBox" name="showExpiredEntriesOnDatabaseUnlockOffsetSpinBox">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
@ -313,7 +307,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="2">
|
||||
<item>
|
||||
<spacer name="showExpiredEntriesSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
@ -374,6 +368,25 @@
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_11">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Fixed</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>30</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="sizePolicy">
|
||||
@ -383,41 +396,70 @@
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Backup destination</string>
|
||||
<string>Destination format:</string>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>backupFilePath</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_13">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Fixed</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>6</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="backupFilePath">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Specifies the database backup file location. Occurrences of "{DB_FILENAME}" are replaced with the filename of the saved database without extension. {TIME:<format>} is replaced with the backup time, see https://doc.qt.io/qt-5/qdatetime.html#toString. <format> defaults to format string "dd_MM_yyyy_hh-mm-ss".</string>
|
||||
<string><html><head/><body><p><span style=" font-weight:600;">{DB_FILENAME}</span> is replaced with the filename of the saved database without extension</p><p><span style=" font-weight:600;">{TIME:&lt;format&gt;}</span> is replaced with the specified time format (default: dd_MM_yyyy_hh-mm-ss)</p><p>See the User Guide for more details</p></body></html></string>
|
||||
</property>
|
||||
<property name="placeholderText">
|
||||
<string>{DB_FILENAME}.old.kdbx</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_12">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Fixed</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>6</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="backupFilePathPicker">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Choose...</string>
|
||||
<string>Choose folder...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="useAlternativeSaveCheckBox">
|
||||
<property name="text">
|
||||
@ -487,6 +529,20 @@
|
||||
<string>Entry Management</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="ConfirmMoveEntryToRecycleBinCheckBox">
|
||||
<property name="text">
|
||||
<string>Show confirmation before moving entries to recycle bin</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="EnableCopyOnDoubleClickCheckBox">
|
||||
<property name="text">
|
||||
<string>Copy data on double clicking field in entry view</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="useGroupIconOnEntryCreationCheckBox">
|
||||
<property name="text">
|
||||
@ -643,6 +699,35 @@
|
||||
<property name="horizontalSpacing">
|
||||
<number>10</number>
|
||||
</property>
|
||||
<item row="1" column="2">
|
||||
<widget class="QCheckBox" name="toolbarMovableCheckBox">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Movable toolbar</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="3">
|
||||
<spacer name="horizontalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QComboBox" name="toolButtonStyleComboBox">
|
||||
<property name="sizePolicy">
|
||||
@ -662,19 +747,28 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2">
|
||||
<widget class="QCheckBox" name="toolbarMovableCheckBox">
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="toolButtonStyleLabel">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">margin-right: 5px</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Movable toolbar</string>
|
||||
<string>Toolbar button style:</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>toolButtonStyleComboBox</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@ -720,45 +814,24 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="3">
|
||||
<spacer name="horizontalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="toolButtonStyleLabel">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">margin-right: 5px</string>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="toolbarShowCheckBox">
|
||||
<property name="text">
|
||||
<string>Toolbar button style:</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>toolButtonStyleComboBox</cstring>
|
||||
<string>Show toolbar</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="menubarShowCheckBox">
|
||||
<property name="toolTip">
|
||||
<string>Show the menu bar by pressing the Alt key</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Show menubar</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="colorPasswordsCheckBox">
|
||||
@ -941,7 +1014,7 @@
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="resetSettingsSubLayout">
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
<number>6</number>
|
||||
</property>
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetMaximumSize</enum>
|
||||
@ -954,21 +1027,32 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="spacer4">
|
||||
<spacer name="horizontalSpacer_10">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Expanding</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>50</width>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="importSettingsButton">
|
||||
<property name="text">
|
||||
<string>Import settings…</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="exportSettingsButton">
|
||||
<property name="text">
|
||||
<string>Export settings…</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
@ -1265,6 +1349,8 @@
|
||||
<tabstop>backupFilePathPicker</tabstop>
|
||||
<tabstop>useAlternativeSaveCheckBox</tabstop>
|
||||
<tabstop>alternativeSaveComboBox</tabstop>
|
||||
<tabstop>ConfirmMoveEntryToRecycleBinCheckBox</tabstop>
|
||||
<tabstop>EnableCopyOnDoubleClickCheckBox</tabstop>
|
||||
<tabstop>useGroupIconOnEntryCreationCheckBox</tabstop>
|
||||
<tabstop>minimizeOnOpenUrlCheckBox</tabstop>
|
||||
<tabstop>hideWindowOnCopyCheckBox</tabstop>
|
||||
@ -1274,6 +1360,8 @@
|
||||
<tabstop>languageComboBox</tabstop>
|
||||
<tabstop>toolButtonStyleComboBox</tabstop>
|
||||
<tabstop>toolbarMovableCheckBox</tabstop>
|
||||
<tabstop>toolbarShowCheckBox</tabstop>
|
||||
<tabstop>menubarShowCheckBox</tabstop>
|
||||
<tabstop>colorPasswordsCheckBox</tabstop>
|
||||
<tabstop>monospaceNotesCheckBox</tabstop>
|
||||
<tabstop>minimizeOnCloseCheckBox</tabstop>
|
||||
@ -1281,6 +1369,8 @@
|
||||
<tabstop>trayIconAppearance</tabstop>
|
||||
<tabstop>systrayMinimizeToTrayCheckBox</tabstop>
|
||||
<tabstop>resetSettingsButton</tabstop>
|
||||
<tabstop>importSettingsButton</tabstop>
|
||||
<tabstop>exportSettingsButton</tabstop>
|
||||
<tabstop>autoTypeEntryTitleMatchCheckBox</tabstop>
|
||||
<tabstop>autoTypeEntryURLMatchCheckBox</tabstop>
|
||||
<tabstop>autoTypeAskCheckBox</tabstop>
|
||||
|
@ -7,7 +7,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>364</width>
|
||||
<height>493</height>
|
||||
<height>505</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
@ -31,7 +31,7 @@
|
||||
<property name="title">
|
||||
<string>Timeouts</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout" columnstretch="0,0,0">
|
||||
<layout class="QGridLayout" name="gridLayout" columnstretch="0,0,1">
|
||||
<item row="1" column="1">
|
||||
<widget class="QSpinBox" name="lockDatabaseIdleSpinBox">
|
||||
<property name="enabled">
|
||||
@ -160,11 +160,11 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<widget class="QGroupBox" name="lockOptionsGroup">
|
||||
<property name="title">
|
||||
<string>Convenience</string>
|
||||
<string>Lock Options</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="quickUnlockCheckBox">
|
||||
<property name="text">
|
||||
@ -179,13 +179,6 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="lockDatabaseMinimizeCheckBox">
|
||||
<property name="text">
|
||||
<string>Lock databases after minimizing the window</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="lockDatabasesOnUserSwitchCheckBox">
|
||||
<property name="text">
|
||||
@ -194,12 +187,21 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="passwordsHiddenCheckBox">
|
||||
<widget class="QCheckBox" name="lockDatabaseMinimizeCheckBox">
|
||||
<property name="text">
|
||||
<string>Hide passwords when editing them</string>
|
||||
<string>Lock databases after minimizing the window</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<property name="title">
|
||||
<string>Convenience</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="passwordShowDotsCheckBox">
|
||||
<property name="text">
|
||||
@ -207,6 +209,13 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="passwordsHiddenCheckBox">
|
||||
<property name="text">
|
||||
<string>Hide passwords when editing them</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="passwordPreviewCleartextCheckBox">
|
||||
<property name="text">
|
||||
@ -224,21 +233,7 @@
|
||||
<item>
|
||||
<widget class="QCheckBox" name="hideNotesCheckBox">
|
||||
<property name="text">
|
||||
<string>Hide entry notes by default</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="NoConfirmMoveEntryToRecycleBinCheckBox">
|
||||
<property name="text">
|
||||
<string>Move entries to recycle bin without confirmation</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="EnableCopyOnDoubleClickCheckBox">
|
||||
<property name="text">
|
||||
<string>Enable double click to copy the username/password entry columns</string>
|
||||
<string>Hide notes in the entry preview panel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@ -284,19 +279,17 @@
|
||||
<tabstop>clearClipboardSpinBox</tabstop>
|
||||
<tabstop>lockDatabaseIdleCheckBox</tabstop>
|
||||
<tabstop>lockDatabaseIdleSpinBox</tabstop>
|
||||
<tabstop>lockDatabasesOnUserSwitchCheckBox</tabstop>
|
||||
<tabstop>clearSearchCheckBox</tabstop>
|
||||
<tabstop>clearSearchSpinBox</tabstop>
|
||||
<tabstop>quickUnlockCheckBox</tabstop>
|
||||
<tabstop>lockDatabaseOnScreenLockCheckBox</tabstop>
|
||||
<tabstop>lockDatabasesOnUserSwitchCheckBox</tabstop>
|
||||
<tabstop>lockDatabaseMinimizeCheckBox</tabstop>
|
||||
<tabstop>passwordsHiddenCheckBox</tabstop>
|
||||
<tabstop>passwordShowDotsCheckBox</tabstop>
|
||||
<tabstop>passwordsHiddenCheckBox</tabstop>
|
||||
<tabstop>passwordPreviewCleartextCheckBox</tabstop>
|
||||
<tabstop>hideTotpCheckBox</tabstop>
|
||||
<tabstop>hideNotesCheckBox</tabstop>
|
||||
<tabstop>NoConfirmMoveEntryToRecycleBinCheckBox</tabstop>
|
||||
<tabstop>EnableCopyOnDoubleClickCheckBox</tabstop>
|
||||
<tabstop>fallbackToSearch</tabstop>
|
||||
</tabstops>
|
||||
<resources/>
|
||||
|
@ -1704,6 +1704,8 @@ void MainWindow::applySettingsChanges()
|
||||
m_inactivityTimer->deactivate();
|
||||
}
|
||||
|
||||
m_ui->actionShowToolbar->setChecked(!config()->get(Config::GUI_HideToolbar).toBool());
|
||||
m_ui->actionShowMenubar->setChecked(!config()->get(Config::GUI_HideMenubar).toBool());
|
||||
m_ui->menubar->setHidden(config()->get(Config::GUI_HideMenubar).toBool());
|
||||
m_ui->toolBar->setHidden(config()->get(Config::GUI_HideToolbar).toBool());
|
||||
auto movable = config()->get(Config::GUI_MovableToolbar).toBool();
|
||||
|
Loading…
Reference in New Issue
Block a user