mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-29 01:06:27 -05:00
Add compression option to database settings
This commit is contained in:
parent
50beac2baf
commit
75d2895db6
@ -79,6 +79,8 @@ void DatabaseSettingsWidget::load(Database* db)
|
||||
m_uiGeneral->dbDescriptionEdit->setText(meta->description());
|
||||
m_uiGeneral->recycleBinEnabledCheckBox->setChecked(meta->recycleBinEnabled());
|
||||
m_uiGeneral->defaultUsernameEdit->setText(meta->defaultUserName());
|
||||
m_uiGeneral->compressionCheckbox->setChecked(m_db->compressionAlgo() != Database::CompressionNone);
|
||||
|
||||
if (meta->historyMaxItems() > -1) {
|
||||
m_uiGeneral->historyMaxItemsSpinBox->setValue(meta->historyMaxItems());
|
||||
m_uiGeneral->historyMaxItemsCheckBox->setChecked(true);
|
||||
@ -168,6 +170,8 @@ void DatabaseSettingsWidget::save()
|
||||
}
|
||||
}
|
||||
|
||||
m_db->setCompressionAlgo(m_uiGeneral->compressionCheckbox->isChecked() ? Database::CompressionGZip : Database::CompressionNone);
|
||||
|
||||
Metadata* meta = m_db->metadata();
|
||||
|
||||
meta->setName(m_uiGeneral->dbNameEdit->text());
|
||||
|
@ -134,6 +134,25 @@
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_3">
|
||||
<property name="title">
|
||||
<string>Additional Database Settings</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="compressionCheckbox">
|
||||
<property name="text">
|
||||
<string>Enable &compression (recommended)</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
|
Loading…
Reference in New Issue
Block a user