Added 'compression' checkbox to backup GUI
Added 'compress the backup' checkbox to the backup GUI. fixes QubesOS/qubes-issues#943
This commit is contained in:
parent
7fd0c58303
commit
67a32b5748
@ -139,6 +139,9 @@ class BackupVMsWindow(ui_backupdlg.Ui_Backup, multiselectwidget.QtGui.QWizard):
|
|||||||
self.passphrase_line_edit_verify.setText(
|
self.passphrase_line_edit_verify.setText(
|
||||||
profile_data['passphrase_text'])
|
profile_data['passphrase_text'])
|
||||||
|
|
||||||
|
if 'compression' in profile_data:
|
||||||
|
self.compress_checkbox.setChecked(profile_data['compression'])
|
||||||
|
|
||||||
if 'include' in profile_data:
|
if 'include' in profile_data:
|
||||||
return profile_data['include']
|
return profile_data['include']
|
||||||
|
|
||||||
@ -148,8 +151,8 @@ class BackupVMsWindow(ui_backupdlg.Ui_Backup, multiselectwidget.QtGui.QWizard):
|
|||||||
settings = {'destination_vm': self.appvm_combobox.currentText(),
|
settings = {'destination_vm': self.appvm_combobox.currentText(),
|
||||||
'destination_path': self.dir_line_edit.text(),
|
'destination_path': self.dir_line_edit.text(),
|
||||||
'include': [vm.name for vm in self.selected_vms],
|
'include': [vm.name for vm in self.selected_vms],
|
||||||
'passphrase_text': self.passphrase_line_edit.text()}
|
'passphrase_text': self.passphrase_line_edit.text(),
|
||||||
# TODO: add compression when it is added
|
'compression': self.compress_checkbox.isChecked()}
|
||||||
|
|
||||||
backup_utils.write_backup_profile(settings, use_temp)
|
backup_utils.write_backup_profile(settings, use_temp)
|
||||||
|
|
||||||
|
@ -100,7 +100,6 @@ def write_backup_profile(args, use_temp=False):
|
|||||||
|
|
||||||
path = get_profile_path(use_temp)
|
path = get_profile_path(use_temp)
|
||||||
|
|
||||||
# TODO add compression parameter to GUI issue#943
|
|
||||||
with open(path, 'w') as profile_file:
|
with open(path, 'w') as profile_file:
|
||||||
yaml.safe_dump(profile_data, profile_file)
|
yaml.safe_dump(profile_data, profile_file)
|
||||||
|
|
||||||
|
@ -80,6 +80,16 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QCheckBox" name="compress_checkbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>Compress the backup</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="unrecognized_config_label">
|
<widget class="QLabel" name="unrecognized_config_label">
|
||||||
<property name="palette">
|
<property name="palette">
|
||||||
|
Loading…
Reference in New Issue
Block a user