summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cmdline.py15
-rwxr-xr-xgui.py35
-rw-r--r--text.py30
3 files changed, 0 insertions, 80 deletions
diff --git a/cmdline.py b/cmdline.py
index 4e90fc3db..7b925c9cf 100644
--- a/cmdline.py
+++ b/cmdline.py
@@ -107,20 +107,6 @@ class InstallInterface:
def exceptionWindow(self, shortText, longTextFile):
print(shortText)
- def partedExceptionWindow(self, exc):
- # if our only option is to cancel, let us handle the exception
- # in our code and avoid popping up the exception window here.
- log.critical("parted exception: %s: %s" %(exc.type_string,exc.message))
- if exc.options == parted.EXCEPTION_CANCEL:
- return parted.EXCEPTION_UNHANDLED
-
- print(_("Parted exceptions can't be handled in command line mode!"))
- print(exc.message)
-
- # don't exit
- while 1:
- time.sleep(5)
-
def waitWindow(self, title, text):
return WaitWindow(title, text)
@@ -131,7 +117,6 @@ class InstallInterface:
anaconda.id.fsset.registerMessageWindow(self.messageWindow)
anaconda.id.fsset.registerProgressWindow(self.progressWindow)
anaconda.id.fsset.registerWaitWindow(self.waitWindow)
- parted.exception_set_handler(self.partedExceptionWindow)
(step, instance) = anaconda.dispatch.currentStep()
while step:
diff --git a/gui.py b/gui.py
index fca3a0dd6..14ef0450e 100755
--- a/gui.py
+++ b/gui.py
@@ -212,39 +212,6 @@ def processEvents():
while gtk.events_pending():
gtk.main_iteration(False)
-def partedExceptionWindow(exc):
- # if our only option is to cancel, let us handle the exception
- # in our code and avoid popping up the exception window here.
- if exc.options == parted.EXCEPTION_CANCEL:
- return parted.EXCEPTION_UNHANDLED
- log.critical("parted exception: %s: %s" %(exc.type_string,exc.message))
- print(exc.type_string)
- print(exc.message)
- print(exc.options)
- win = gtk.Dialog(exc.type_string, mainWindow, gtk.DIALOG_MODAL)
- addFrame(win)
- win.set_position(gtk.WIN_POS_CENTER)
- label = WrappingLabel(exc.message)
- win.vbox.pack_start (label)
- numButtons = 0
- buttonToAction = {}
-
- exflags = ((parted.EXCEPTION_FIX, N_("Fix")),
- (parted.EXCEPTION_YES, N_("Yes")),
- (parted.EXCEPTION_NO, N_("No")),
- (parted.EXCEPTION_OK, N_("OK")),
- (parted.EXCEPTION_RETRY, N_("Retry")),
- (parted.EXCEPTION_IGNORE, N_("Ignore")),
- (parted.EXCEPTION_CANCEL, N_("Cancel")))
- for flag, string in exflags:
- if exc.options & flag:
- win.add_button(_(string), flag)
- win.show_all()
- rc = win.run()
- win.destroy()
-
- return rc
-
def widgetExpander(widget, growTo=None):
widget.connect("size-allocate", growToParent, growTo)
@@ -1304,8 +1271,6 @@ class InstallInterface:
anaconda.id.fsset.registerProgressWindow(self.progressWindow)
anaconda.id.fsset.registerWaitWindow(self.waitWindow)
- parted.exception_set_handler(partedExceptionWindow)
-
self.icw = InstallControlWindow (self.anaconda)
self.icw.run (self.runres)
diff --git a/text.py b/text.py
index a632b782d..e518e84f5 100644
--- a/text.py
+++ b/text.py
@@ -557,34 +557,6 @@ class InstallInterface:
win = SaveExceptionWindow (anaconda, longTextFile, self.screen)
return win
- def partedExceptionWindow(self, exc):
- # if our only option is to cancel, let us handle the exception
- # in our code and avoid popping up the exception window here.
- if exc.options == parted.EXCEPTION_CANCEL:
- return parted.EXCEPTION_UNHANDLED
- log.critical("parted exception: %s: %s" %(exc.type_string,exc.message))
- buttons = []
- buttonToAction = {}
- flags = ((parted.EXCEPTION_FIX, N_("Fix")),
- (parted.EXCEPTION_YES, N_("Yes")),
- (parted.EXCEPTION_NO, N_("No")),
- (parted.EXCEPTION_OK, N_("OK")),
- (parted.EXCEPTION_RETRY, N_("Retry")),
- (parted.EXCEPTION_IGNORE, N_("Ignore")),
- (parted.EXCEPTION_CANCEL, N_("Cancel")))
- for flag, errorstring in flags:
- if exc.options & flag:
- buttons.append(_(errorstring))
- buttonToAction[string.lower(_(errorstring))] = flag
-
- rc = None
- while not buttonToAction.has_key(rc):
- rc = ButtonChoiceWindow(self.screen, exc.type_string, exc.message,
- buttons=buttons)
-
- return buttonToAction[rc]
-
-
def waitWindow(self, title, text):
return WaitWindow(self.screen, title, text)
@@ -661,8 +633,6 @@ class InstallInterface:
anaconda.id.fsset.registerProgressWindow(self.progressWindow)
anaconda.id.fsset.registerWaitWindow(self.waitWindow)
- parted.exception_set_handler(self.partedExceptionWindow)
-
lastrc = INSTALL_OK
(step, instance) = anaconda.dispatch.currentStep()
while step: