diff options
author | Jeremy Katz <katzj@redhat.com> | 2006-01-26 03:14:52 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2006-01-26 03:14:52 +0000 |
commit | 374b93455d2ad1c6d717c856731acf471f39a4e7 (patch) | |
tree | 0dea48ef3c12271565c903f6ee4479bfa17167ce /iw | |
parent | 7d1d0da1d8a63eb025fb25ff04bc2d3961152fc3 (diff) | |
download | anaconda-374b93455d2ad1c6d717c856731acf471f39a4e7.tar.gz anaconda-374b93455d2ad1c6d717c856731acf471f39a4e7.tar.xz anaconda-374b93455d2ad1c6d717c856731acf471f39a4e7.zip |
2006-01-25 Jeremy Katz <katzj@redhat.com>
* textw/packages_text.py: Remove obsolete file.
* iw/package_gui.py: Likewise.
* iw/dependencies_gui.py: Likewise.
* gui.py: Remove obsolete steps.
* text.py: Likewise.
* iw/partition_gui.py (AutoPartitionWindow): Remove obsolete code.
* textw/partition_text.py (AutoPartitionWindow): Likewise.
Diffstat (limited to 'iw')
-rw-r--r-- | iw/dependencies_gui.py | 114 | ||||
-rw-r--r-- | iw/package_gui.py | 30 | ||||
-rw-r--r-- | iw/partition_gui.py | 141 |
3 files changed, 0 insertions, 285 deletions
diff --git a/iw/dependencies_gui.py b/iw/dependencies_gui.py deleted file mode 100644 index 8d26fb31c..000000000 --- a/iw/dependencies_gui.py +++ /dev/null @@ -1,114 +0,0 @@ -# -# dependencies_gui.py: screen to allow resolution of unresolved dependencies. -# -# Copyright 2000-2002 Red Hat, Inc. -# -# This software may be freely redistributed under the terms of the GNU -# library public license. -# -# You should have received a copy of the GNU Library Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -# - -import gobject -import gtk -from iw_gui import * -from rhpl.translate import _, N_ - -class UnresolvedDependenciesWindow (InstallWindow): - - windowTitle = N_("Unresolved Dependencies") - htmlTag = "depend" - - def __init__ (self, ics): - InstallWindow.__init__ (self, ics) - self.dependRB = None - self.causeRB = None - self.ics = ics - - def getPrev (self): - self.comps.setSelectionState(self.origSelection) - - def updateSize (self, *args): - self.sizelabel.set_text (_("Total install size: %s") % self.comps.sizeStr()) - - def installToggled (self, widget, *args): - self.comps.selectDepCause (self.deps) - if widget.get_active (): - self.comps.selectDeps (self.deps) - else: - self.comps.unselectDeps (self.deps) - self.updateSize () - - def causeToggled (self, widget, *args): - if widget.get_active (): - self.comps.unselectDepCause (self.deps) - else: - self.comps.selectDepCause (self.deps) - self.updateSize () - - def ignoreToggled (self, widget, *args): - if widget.get_active (): - self.comps.selectDepCause (self.deps) - self.comps.unselectDeps (self.deps) - self.updateSize () - - #UnresolvedDependenciesWindow tag="depend" - def getScreen (self, comps, deps): - self.ics.setHelpEnabled(True) - self.deps = deps - self.comps = comps - - sw = gtk.ScrolledWindow () - sw.set_border_width (5) - sw.set_policy (gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC) - - store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING) - for (name, suggest) in self.deps: - iter = store.append() - store.set_value(iter, 0, name) - store.set_value(iter, 1, suggest) - - view = gtk.TreeView(store) - col = gtk.TreeViewColumn(_("Package"), gtk.CellRendererText(), text=0) - view.append_column(col) - col = gtk.TreeViewColumn(_("Requirement"), gtk.CellRendererText(), - text=1) - view.append_column(col) - sw.add (view) - - # assume things will be selected -- that matches our default - self.origSelection = self.comps.getSelectionState() - self.comps.selectDeps (self.deps) - - self.sizelabel = gtk.Label("") - self.sizelabel.set_alignment (1, .5) - self.updateSize() - - rb = gtk.VBox (False) - self.dependRB = gtk.RadioButton (None, _("_Install packages to " - "satisfy dependencies")) - - self.causeRB = gtk.RadioButton (self.dependRB, _("_Do not install " - "packages that " - "have dependencies")) - - self.ignoreRB = gtk.RadioButton (self.dependRB, _("I_gnore package " - "dependencies")) - - rb.pack_start (self.dependRB) - rb.pack_start (self.causeRB) - rb.pack_start (self.ignoreRB) - rb.pack_start (self.sizelabel) - - self.dependRB.set_active (1) - self.dependRB.connect('toggled', self.installToggled) - self.causeRB.connect('toggled', self.causeToggled) - self.ignoreRB.connect('toggled', self.ignoreToggled) - - box = gtk.VBox (False, 5) - box.pack_start (sw, True) - box.pack_start (rb, False) - - return box diff --git a/iw/package_gui.py b/iw/package_gui.py deleted file mode 100644 index 800d8568e..000000000 --- a/iw/package_gui.py +++ /dev/null @@ -1,30 +0,0 @@ -# -# package_gui.py: package group selection screen -# -# Jeremy Katz <katzj@redhat.com> -# -# Copyright 2005 Red Hat, Inc. -# -# This software may be freely redistributed under the terms of the GNU -# general public license. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -# - -# FIXME: group selection isn't currently backend independent -from GroupSelector import GroupSelector - -import gui -from iw_gui import * -from rhpl.translate import _, N_ - -class GroupSelectionWindow (InstallWindow): - def getScreen(self, backend, intf): - self.backend = backend - self.intf = intf - self.grpsel = GroupSelector(self.backend.ayum, gui.findGladeFile, - gui.addFrame) - self.grpsel.doRefresh() - return self.grpsel.vbox diff --git a/iw/partition_gui.py b/iw/partition_gui.py index b2e81e76d..8a6f91030 100644 --- a/iw/partition_gui.py +++ b/iw/partition_gui.py @@ -1411,144 +1411,3 @@ class PartitionWindow(InstallWindow): vpaned.set_position(175) return vpaned - -class AutoPartitionWindow(InstallWindow): - def __init__(self, ics): - InstallWindow.__init__(self, ics) - ics.setTitle(_("Automatic Partitioning")) - ics.setNextEnabled(True) - ics.readHTML("autopart") - self.parent = ics.getICW().window - - def getNext(self): - if self.clearLinuxRB.get_active(): - self.partitions.autoClearPartType = autopart.CLEARPART_TYPE_LINUX - elif self.clearAllRB.get_active(): - self.partitions.autoClearPartType = autopart.CLEARPART_TYPE_ALL - else: - self.partitions.autoClearPartType = autopart.CLEARPART_TYPE_NONE - - allowdrives = [] - model = self.drivelist.get_model() - iter = model.get_iter_first() - while iter: - val = model.get_value(iter, 0) - drive = model.get_value(iter, 1) - - if val: - allowdrives.append(drive) - - iter = model.iter_next(iter) - - if len(allowdrives) < 1: - mustHaveSelectedDrive(self.intf) - raise gui.StayOnScreen - - self.partitions.autoClearPartDrives = allowdrives - - if not autopart.queryAutoPartitionOK(self.intf, self.diskset, - self.partitions): - raise gui.StayOnScreen - - if self.inspect.get_active(): - self.dispatch.skipStep("partition", skip = 0) - else: - self.dispatch.skipStep("partition") - - return None - - - def getScreen(self, diskset, partitions, intf, dispatch): - - self.diskset = diskset - self.partitions = partitions - self.intf = intf - self.dispatch = dispatch - - type = partitions.autoClearPartType - cleardrives = partitions.autoClearPartDrives - - box = gtk.VBox(False) - box.set_border_width(5) - - label = gui.WrappingLabel(_(autopart.AUTOPART_DISK_CHOICE_DESCR_TEXT)) - label.set_alignment(0.0, 0.0) - box.pack_start(label, False, False) - - # what partition types to remove - clearbox = gtk.VBox(False) - label = gui.WrappingLabel(_("I want to have automatic partitioning:")) - label.set_alignment(0.0, 0.0) - clearbox.pack_start(label, False, False, 10) - - radioBox = gtk.VBox(False) - self.clearLinuxRB = gtk.RadioButton( - None, _(autopart.CLEARPART_TYPE_LINUX_DESCR_TEXT)) - radioBox.pack_start(self.clearLinuxRB, False, False) - self.clearAllRB = gtk.RadioButton( - self.clearLinuxRB, _(autopart.CLEARPART_TYPE_ALL_DESCR_TEXT)) - radioBox.pack_start(self.clearAllRB, False, False) - self.clearNoneRB = gtk.RadioButton( - self.clearLinuxRB, _(autopart.CLEARPART_TYPE_NONE_DESCR_TEXT)) - radioBox.pack_start(self.clearNoneRB, False, False) - - if type == autopart.CLEARPART_TYPE_LINUX: - self.clearLinuxRB.set_active(1) - elif type == autopart.CLEARPART_TYPE_ALL: - self.clearAllRB.set_active(1) - else: - self.clearNoneRB.set_active(1) - - align = gtk.Alignment() - align.add(radioBox) - align.set(0.5, 0.5, 0.0, 0.0) - clearbox.pack_start(align, False, False) - - box.pack_start(clearbox, False, False, 10) - - # which drives to use? - drivesbox = gtk.VBox(False) - label = gui.WrappingLabel(_("Select the drive(s) to use for " - "this installation:")) - label.set_alignment(0.0, 0.0) - drivesbox.pack_start(label, False, False, 10) - self.drivelist = createAllowedDrivesList(diskset.disks, cleardrives) - - # XXX bad use of usize - self.drivelist.set_size_request(375, 80) - - sw = gtk.ScrolledWindow() - sw.add(self.drivelist) - sw.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC) - sw.set_shadow_type(gtk.SHADOW_IN) - - align = gtk.Alignment() - align.add(sw) - align.set(0.5, 0.5, 0.0, 0.0) - - drivesbox.pack_start(align, False, False) - - box.pack_start(drivesbox, False, False) - - self.inspect = gtk.CheckButton() - gui.widgetExpander(self.inspect) - label = gui.MnemonicLabel(_("Re_view (and modify if needed) " - "the partitions created")) - label.set_mnemonic_widget(self.inspect) - label.set_line_wrap(True) - gui.widgetExpander(label, self.inspect) - label.set_alignment(0.0, 1.0) - self.inspect.add(label) - - self.inspect.set_active(not dispatch.stepInSkipList("partition")) - - box.pack_start(self.inspect, True, True, 10) - - self.ics.setNextEnabled(True) - - align = gtk.Alignment() - align.add(box) - align.set(0.5, 0.5, 0.0, 0.0) - - return align - |