[PATCH 2/2] Allow double-click edit of LV, MD and delete of LV from part gui. (#525171)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This restores some of the pre-F11 behavior to the partition gui.
 - double-clicking on a VG, LV, or MD array triggers edit dialog
 - LVs can be deleted using the "Delete" button on the main screen
---
 iw/partition_gui.py |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/iw/partition_gui.py b/iw/partition_gui.py
index e295e92..fa91158 100644
--- a/iw/partition_gui.py
+++ b/iw/partition_gui.py
@@ -709,7 +709,7 @@ class PartitionWindow(InstallWindow):
 		    else:
 			self.tree[iter]['Mount Point'] = ""
 		    self.tree[iter]['Size (MB)'] = "%Ld" % lv.size
-		    self.tree[iter]['PyObject'] = vg
+		    self.tree[iter]['PyObject'] = lv
 		
                     if lv.format.type == "luks" and not lv.format.exists:
                         # we're creating the LUKS header
@@ -954,8 +954,8 @@ class PartitionWindow(InstallWindow):
         self.treeView.expand_all()
 
     def treeActivateCB(self, view, path, col):
-        if isinstance(self.tree.getCurrentDevice(),
-                      storage.devices.PartitionDevice):
+        device = self.tree.getCurrentDevice()
+        if device.type in ("partition", "lvmlv", "lvmvg", "mdarray"):
             self.editCB()
 
     def treeSelectCB(self, selection, *args):
@@ -1078,7 +1078,7 @@ class PartitionWindow(InstallWindow):
         elif device.type == "lvmvg":
             self.editLVMVolumeGroup(device)
         elif device.type == "lvmlv":
-            self.editLVMVolumeGroup(device)
+            self.editLVMVolumeGroup(device.vg)
         elif isinstance(device, storage.devices.PartitionDevice):
             self.editPartition(device)
 
-- 
1.6.0.6

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux