diff options
author | Jeremy Katz <katzj@redhat.com> | 2001-07-30 22:56:01 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2001-07-30 22:56:01 +0000 |
commit | a5c7ccbcb7b41f44d26c3f4d0efba74d973499f9 (patch) | |
tree | 682168722bda648535e5764528b6634d0a99a89f | |
parent | 50fff494de5f04c534bf1ec2c58c21f6b49a6cfd (diff) | |
download | anaconda-a5c7ccbcb7b41f44d26c3f4d0efba74d973499f9.tar.gz anaconda-a5c7ccbcb7b41f44d26c3f4d0efba74d973499f9.tar.xz anaconda-a5c7ccbcb7b41f44d26c3f4d0efba74d973499f9.zip |
register the wait window with the fsset so we can pop up a "Checking for badanaconda-s390-tag
blocks" window
-rw-r--r-- | fsset.py | 18 | ||||
-rwxr-xr-x | gui.py | 1 | ||||
-rw-r--r-- | text.py | 1 |
3 files changed, 18 insertions, 2 deletions
@@ -136,13 +136,23 @@ class FileSystemType: def registerDeviceArgumentFunction(self, klass, function): self.deviceArguments[klass] = function - def badblocksDevice(self, entry, progress, chroot='/'): + def badblocksDevice(self, entry, windowCreator, chroot='/'): + if windowCreator: + w = windowCreator(_("Checking for Bad Blocks"), + _("Checking for bad blocks on /dev/%s...") + % (entry.device.getDevice(),)) + else: + w = None + devicePath = entry.device.setupDevice(chroot) args = [ "badblocks", "-vv", devicePath ] rc = iutil.execWithRedirect("/usr/sbin/badblocks", args, stdout = "/dev/tty5", stderr = "/dev/tty5") + + w and w.pop() + if rc: raise SystemError @@ -464,6 +474,7 @@ class FileSystemSet: def __init__(self): self.messageWindow = None self.progressWindow = None + self.waitWindow = None self.mountcount = 0 self.reset() @@ -476,6 +487,9 @@ class FileSystemSet: def registerProgressWindow(self, method): self.progressWindow = method + def registerWaitWindow(self, method): + self.waitWindow = method + def reset (self): self.entries = [] proc = FileSystemSetEntry(Device(), '/proc', fileSystemTypeGet("proc")) @@ -734,7 +748,7 @@ class FileSystemSet: entry.fsystem.formatDevice(entry, self.progressWindow, chroot) def badblocksEntry(self, entry, chroot): - entry.fsystem.badblocksDevice(entry, self.progressWindow, chroot) + entry.fsystem.badblocksDevice(entry, self.waitWindow, chroot) def getMigratableEntries(self): retval = [] @@ -340,6 +340,7 @@ class InstallInterface: id.fsset.registerMessageWindow(self.messageWindow) id.fsset.registerProgressWindow(self.progressWindow) + id.fsset.registerWaitWindow(self.waitWindow) parted.exception_set_handler(partedExceptionWindow) lang = id.instLanguage.getCurrent() @@ -341,6 +341,7 @@ class InstallInterface: id.fsset.registerMessageWindow(self.messageWindow) id.fsset.registerProgressWindow(self.progressWindow) + id.fsset.registerWaitWindow(self.waitWindow) parted.exception_set_handler(self.partedExceptionWindow) lastrc = INSTALL_OK |