From: Michael Tremer Date: Sun, 24 May 2009 20:23:33 +0000 (+0200) Subject: Daily checkin. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=930ac77fc00c07dfd9617c66b6be518b261a6925;p=ipfire-3.x.git Daily checkin. --- diff --git a/src/pomona/partition.py b/src/pomona/partition.py index 1eaa4be3f..3acd670ab 100644 --- a/src/pomona/partition.py +++ b/src/pomona/partition.py @@ -145,7 +145,20 @@ class PartitionWindow(object): self.newLV() def newPart(self): - device = self.storage.newPartition() + disks = [] + for disk in self.storage.disks: + disks.append(("%s - %s" % (disk.name, disk.model,), disk,)) + + (button, disk) = ListboxChoiceWindow(self.installer.intf.screen, + _("Disk Selection"), + _("Choose the disk you want create the new " + "partition on."), + disks, buttons = [TEXT_OK_BUTTON, TEXT_CANCEL_BUTTON], + height=len(disks)) + if button == TEXT_CANCEL_CHECK: + return + + device = self.storage.newPartition(parents=disk) self.editPart(device=device) def newVG(self): @@ -184,12 +197,15 @@ class PartitionWindow(object): if not device.exists: subgrid1 = Grid(2, 1) - - (devgrid, drivelist) = self.makeDriveList(device) - subgrid1.setField(devgrid, 0, 0) (fsgrid, fstype) = self.makeFileSystemList(device) - subgrid1.setField(fsgrid, 1, 0, (1,0,0,0), growx=1) + subgrid1.setField(fsgrid, 0, 0) + + #(devgrid, drivelist) = self.makeDriveList(device) + #subgrid1.setField(devgrid, 0, 0) + + #(fsgrid, fstype) = self.makeFileSystemList(device) + #subgrid1.setField(fsgrid, 1, 0, (1,0,0,0), growx=1) grid.add(subgrid1, 0, row, (0,1,0,0), growx=1) row += 1 diff --git a/src/pomona/storage/formats/__init__.py b/src/pomona/storage/formats/__init__.py index b271c00a2..f73f13840 100644 --- a/src/pomona/storage/formats/__init__.py +++ b/src/pomona/storage/formats/__init__.py @@ -31,9 +31,6 @@ def getFormat(fmt_type, *args, **kwargs): exists -- whether or not the format exists on the device """ - - #installer = kwargs["installer"] - fmt_class = get_device_format_class(fmt_type) fmt = None if fmt_class: @@ -42,7 +39,6 @@ def getFormat(fmt_type, *args, **kwargs): className = fmt.__class__.__name__ except AttributeError: className = None - #installer.log.debug("getFormat('%s') returning %s instance" % (fmt_type, className)) return fmt def get_device_format_class(fmt_type):