diff options
author | Mike Fulbright <msf@redhat.com> | 2003-06-11 23:28:06 +0000 |
---|---|---|
committer | Mike Fulbright <msf@redhat.com> | 2003-06-11 23:28:06 +0000 |
commit | a68ee1010047ba6324865c1f0460ce078cf3da11 (patch) | |
tree | fc5849bb79fbcd630d76413849ca4df233df653f /textw | |
parent | a08e921ea2e4b0bbbdfedd3a0352f356ba36eaaf (diff) | |
download | anaconda-a68ee1010047ba6324865c1f0460ce078cf3da11.tar.gz anaconda-a68ee1010047ba6324865c1f0460ce078cf3da11.tar.xz anaconda-a68ee1010047ba6324865c1f0460ce078cf3da11.zip |
fix generic monitor entries were not at top of list
Diffstat (limited to 'textw')
-rw-r--r-- | textw/xconfig_text.py | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/textw/xconfig_text.py b/textw/xconfig_text.py index a99b85f51..d8f79d427 100644 --- a/textw/xconfig_text.py +++ b/textw/xconfig_text.py @@ -229,7 +229,7 @@ class MonitorWindow: _("Please select the monitor attached to your " "system.") , self.monitorsnames, [ TEXT_OK_BUTTON, TEXT_CANCEL_BUTTON], - scroll = 1, height = 7, help = "monitor", + scroll = 1, height = 12, help = "monitor", default = self.currentMonitor) if button != TEXT_CANCEL_CHECK: @@ -342,13 +342,32 @@ class MonitorWindow: # now read in monitors database self.monDB = self.monitor.monitorsDB() + + # put generic LCD and CRTs first so easy to find + genericnames = [] + for desiredmanf in ['Generic LCD Display', 'Generic CRT Display']: + if desiredmanf in self.monDB.keys(): + for mon in self.monDB[desiredmanf]: + if self.ddcmon and string.upper(self.ddcmon[0]) == string.upper(mon[1]): + continue + self.monitorslist[mon[0]] = mon + genericnames.append(mon[0]) + + # now the rest + remainingnames = [] for man in self.monDB.keys(): + # already inserted these + if man in ['Generic LCD Display', 'Generic CRT Display']: + continue + for mon in self.monDB[man]: if self.ddcmon and string.upper(self.ddcmon[0]) == string.upper(mon[1]): continue - self.monitorslist[mon[0]] = mon - self.monitorsnames = self.monitorslist.keys() - self.monitorsnames.sort() + self.monitorslist[mon[0]] = mon + remainingnames.append(mon[0]) + + remainingnames.sort() + self.monitorsnames = genericnames + remainingnames # Insert DDC probed monitor if it had no match in database # or otherwise if we did not detect a monitor at all |