--- iw/partition_dialog_gui.py | 70 ++++++++++++++++++++++---------------------- 1 files changed, 35 insertions(+), 35 deletions(-) diff --git a/iw/partition_dialog_gui.py b/iw/partition_dialog_gui.py index 1e99b64..29a7ebb 100644 --- a/iw/partition_dialog_gui.py +++ b/iw/partition_dialog_gui.py @@ -224,41 +224,41 @@ class PartitionEditor: devicetree = self.anaconda.id.storage.devicetree if self.fsoptionsDict.has_key("formatcb"): - if self.fsoptionsDict["formatcb"].get_active(): - fmt_class = self.fsoptionsDict["fstypeCombo"].get_active_value() - - # carry over exists, migrate, size, and device - # necessary for partition editor UI - format = fmt_class(mountpoint=mountpoint, - exists=origformat.exists, - size=getattr(origformat, "size", None), - device=usedev.path) - - luksdev = None - if self.fsoptionsDict.has_key("lukscb") and \ - self.fsoptionsDict["lukscb"].get_active() and \ - request.format.type != "luks": - luksdev = LUKSDevice("luks%d" % self.storage.nextID, - format=format, - parents=request) - format = getFormat("luks", - device=self.origrequest.path, - passphrase=self.storage.encryptionPassphrase) - actions.append(ActionCreateFormat(usedev, format)) - if luksdev: - actions.append(ActionCreateDevice(luksdev)) - actions.append(ActionCreateFormat(luksdev)) - elif not self.fsoptionsDict["formatcb"].get_active(): - creates = devicetree.findActions(type="create", - object="format", - path=request.format.device) - for action in creates: - devicetree.cancelAction(action) - - request.format.exists = True - - if request.format.mountable: - request.format.mountpoint = mountpoint + if self.fsoptionsDict["formatcb"].get_active(): + fmt_class = self.fsoptionsDict["fstypeCombo"].get_active_value() + + # carry over exists, migrate, size, and device + # necessary for partition editor UI + format = fmt_class(mountpoint=mountpoint, + exists=origformat.exists, + size=getattr(origformat, "size", None), + device=usedev.path) + + luksdev = None + if self.fsoptionsDict.has_key("lukscb") and \ + self.fsoptionsDict["lukscb"].get_active() and \ + request.format.type != "luks": + luksdev = LUKSDevice("luks%d" % self.storage.nextID, + format=format, + parents=request) + format = getFormat("luks", + device=self.origrequest.path, + passphrase=self.storage.encryptionPassphrase) + actions.append(ActionCreateFormat(usedev, format)) + if luksdev: + actions.append(ActionCreateDevice(luksdev)) + actions.append(ActionCreateFormat(luksdev)) + elif not self.fsoptionsDict["formatcb"].get_active(): + creates = devicetree.findActions(type="create", + object="format", + path=request.format.device) + for action in creates: + devicetree.cancelAction(action) + + request.format.exists = True + + if request.format.mountable: + request.format.mountpoint = mountpoint request.weight = self.anaconda.platform.weight(mountpoint=mountpoint, fstype=request.format.type) -- 1.6.0.6 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list