Re: [PATCH 1/2] cleardisk_gui: Base autoselection of bootdev on detected BIOS order

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> >>@@ -160,19 +165,21 @@ class ClearDisksWindow (InstallWindow):
> >>
> >>          return self.vbox
> >>
> >>+    def _autoSelectBootDisk(self):
> >>+        if self.rightDS.getSelected():
> >>+            return
> >>+
> >>+        for i in range(0, len(self.store)):
> >>+            if self.store[i][OBJECT_COL].name == self.bootDisk and \
> >>+                    self.store[i][self.rightVisible]:
> >>+                self.store[i][self.rightActive] = True
> >
> >gtk.WhateverStores are iterable, so this can be simplified down to:
> >
> >     for row in self.store:
> >         if row[OBJECT_COL].name == self.bootDisk and row[self.rightVisible]:
> >             row[self.rightActive] = True
> >
> 
> Ah yes that is much better, will change in next revision of the patch.

And I'm working on replacing my old busted crud with this style, too.  I
might as well follow my own advice.

> >What happens to the UI if I'm on a machine with no preset boot disk, but
> >then I add several things to the right panel and click next?  Do any of
> >the radio buttons get updated?
> 
> In this case the first drive according to our fallback sorting (used when
> no EDD info is present) gets auto selected (if added to the right column),
> like it was autoselected in the old auto_part_type UI.
> 
> >Does the "You must select one drive to
> >boot from" message still appear?
> 
> If no drive is selected because the first drive according to the compareDisks
> sort order is not added to the right pane, yes (I tested this to make sure).

Okay, good.  This is what I was hoping would happen.

- Chris

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux