diff options
author | Papoteur <papoteur@mageia.org> | 2021-03-21 22:22:48 +0100 |
---|---|---|
committer | Papoteur <papoteur@mageia.org> | 2021-03-21 22:22:48 +0100 |
commit | f1dcc6760e6c4c139b6c6e8b21b82221797206bc (patch) | |
tree | 47a6efa8ad6abb99283bf4da257d72132b914646 /lib | |
parent | e82e78593fa490fe3829c36e4d2199b031fb4003 (diff) | |
download | isodumper-f1dcc6760e6c4c139b6c6e8b21b82221797206bc.tar isodumper-f1dcc6760e6c4c139b6c6e8b21b82221797206bc.tar.gz isodumper-f1dcc6760e6c4c139b6c6e8b21b82221797206bc.tar.bz2 isodumper-f1dcc6760e6c4c139b6c6e8b21b82221797206bc.tar.xz isodumper-f1dcc6760e6c4c139b6c6e8b21b82221797206bc.zip |
Improve activation and deactivation of interface elements
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/isodumper.py | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/lib/isodumper.py b/lib/isodumper.py index 1b5b1b9..0d940c9 100755 --- a/lib/isodumper.py +++ b/lib/isodumper.py @@ -316,6 +316,8 @@ class IsoDumper(basedialog.BaseDialog): self.backup_cbox.setDisabled() self.partition_cbox.setDisabled() self.ima.setDisabled() + self.img_name = "" + self.ima.setLabel(self.ChooseImage) self.write_cbox.setDisabled() self.devicelist.setEnabled() self.progress.setLabel(_("Progress")) @@ -529,6 +531,7 @@ class IsoDumper(basedialog.BaseDialog): self.initial_state() else: self.emergency(message) + self.initial_state() else: self.emergency(message) self.initial_state() @@ -578,7 +581,7 @@ class IsoDumper(basedialog.BaseDialog): def final_unsensitive(self): self.ima.setDisabled() self.devicelist.setDisabled() - self.select_write.setDisabled() + self.write_cbox.setDisabled() self.backup_cbox.setDisabled() self.progress.setDisabled() self.backup_select.setDisabled() @@ -592,6 +595,11 @@ class IsoDumper(basedialog.BaseDialog): self.write_cbox.setDisabled() self.refreshbt.setDisabled() self.partition_cbox.setDisabled() + self.partition_cb.setDisabled() + self.partition_label.setDisabled() + self.cryptcb.setDisabled() + self.cryptkey.setDisabled() + self.start_bt.setDisabled() def close(self): # to exit from _handleEvents loop @@ -864,17 +872,21 @@ exFAT, NTFS or ext. You can specify a volume name and the format in a new dialog else: self.partition_cb.setDisabled() self.partition_label.setDisabled() + self.cryptcb.setDisabled() + self.cryptkey.setDisabled() def select_partition_type(self): if self.partition_cb.value() in ("ext4" ,"Persistent partition"): self.cryptcb.setEnabled() if self.partition_cb.value() == "Persistent partition": self.partition_label.setValue("mgalive-persist") - if self.partition_cb.value() != "": - self.start_bt.setEnabled() else: self.cryptcb.setDisabled() + self.cryptcb.setDisabled() self.cryptkey.setDisabled() + if self.partition_cb.value() != "": + self.start_bt.setEnabled() + else: self.start_bt.setDisabled() def check_encryt(self): @@ -890,13 +902,15 @@ exFAT, NTFS or ext. You can specify a volume name and the format in a new dialog self.backup_go() self.backup_is_selected = False else: - self.emergency(_("No image for backup is selected.")) + info = Info(_("Error"), True, _("No image for backup is selected.")) + self.ask_OK(info) if self.write_cbox.isChecked(): if self.image_is_selected: self.do_write() self.image_is_selected = False else: - self.emergency(_("No image to write is selected.")) + info = Info(_("Error"), True, _("No image to write is selected.")) + self.ask_OK(info) return if self.partition_cbox.isChecked(): # Create a partition without writing image, will use all the device space. |