summaryrefslogtreecommitdiffstats
path: root/installmethod.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2009-03-13 13:34:13 -0400
committerChris Lumens <clumens@redhat.com>2009-03-13 14:26:57 -0400
commit12c4fb21429e61fc0dedbd8e3fd2a2f0d3e3eeac (patch)
tree49266004e7465b89547982458ed990675cb95cba /installmethod.py
parent4f7ad077b523a0dbb1ace6339720f875dec6574f (diff)
downloadanaconda-12c4fb21429e61fc0dedbd8e3fd2a2f0d3e3eeac.tar.gz
anaconda-12c4fb21429e61fc0dedbd8e3fd2a2f0d3e3eeac.tar.xz
anaconda-12c4fb21429e61fc0dedbd8e3fd2a2f0d3e3eeac.zip
Add mediaPresent and eject to the OpticalDevice class.
These no longer belong in isys.py as putting them in the classes is much more correct. I also put a mediaPresent method on Device in general. This will come in handy when we start dealing with USB CF readers and similar devices that can be present without having media.
Diffstat (limited to 'installmethod.py')
-rw-r--r--installmethod.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/installmethod.py b/installmethod.py
index f2c3d7191..c412c944a 100644
--- a/installmethod.py
+++ b/installmethod.py
@@ -34,17 +34,17 @@ def doMethodComplete(anaconda):
return None
if anaconda.mediaDevice:
- return anaconda.mediaDevice
+ return anaconda.id.storage.devicetree.getDeviceByName(anaconda.mediaDevice)
# If we booted off the boot.iso instead of disc 1, eject that as well.
if anaconda.stage2 and anaconda.stage2.startswith("cdrom://"):
dev = anaconda.stage2[8:].split(':')[0]
- return dev
+ return anaconda.id.storage.devicetree.getDeviceByName(dev)
anaconda.backend.complete(anaconda)
dev = _ejectDevice()
if dev:
- isys.ejectCdrom(dev)
+ dev.eject()
mtab = "/dev/root / ext3 ro 0 0\n"
rootDevice = anaconda.id.storage.fsset.rootDevice