[PATCH 2/5] Allow specification of a label for new swap space via custom ui.

David Lehman dlehman at redhat.com
Thu Sep 13 19:51:56 UTC 2012


---
 pyanaconda/ui/gui/spokes/custom.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index f4475c2..c302708 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -1027,7 +1027,8 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
         selectedDeviceDescLabel.set_text(self._description(selector.props.name))
 
         labelEntry.set_text(getattr(device.format, "label", "") or "")
-        can_label = getattr(device.format, "labelfsProg", "") != ""
+        can_label = (hasattr(device.format, "label") and
+                     not device.format.exists)
         labelEntry.set_sensitive(can_label)
 
         if labelEntry.get_sensitive():
-- 
1.7.7.6



More information about the anaconda-patches mailing list