removed debug and add ide-host
authorRonny Strutz <ronny.strutz@multimedia-labs.de>
Tue, 30 Aug 2005 23:37:28 +0000 (23:37 +0000)
committerRonny Strutz <ronny.strutz@multimedia-labs.de>
Tue, 30 Aug 2005 23:37:28 +0000 (23:37 +0000)
lib/python/Components/Harddisk.py
lib/python/Screens/HarddiskSetup.py

index dcf7657..a638977 100644 (file)
@@ -25,11 +25,17 @@ class Harddisk:
                return self.index
 
        def bus(self):
                return self.index
 
        def bus(self):
-               #TODO: add the host
+               ret = ""
+
+               if self.index & 2:
+                       ret = "External (CF) - "
+               else:
+                       ret = "Internal - "
+               
                if self.index & 1:
                if self.index & 1:
-                       return "Slave"
+                       return ret + "Slave"
                else:
                else:
-                       return "Master"
+                       return ret + "Master"
 
        def capacity(self):
                procfile = tryOpen(self.prochdx + "capacity")
 
        def capacity(self):
                procfile = tryOpen(self.prochdx + "capacity")
index 0015828..b644fd9 100644 (file)
@@ -27,6 +27,7 @@ class HarddiskSetup(Screen):
                })
 
        def hddInitialize(self):
                })
 
        def hddInitialize(self):
+               #some protection for the exhibition (IFA 2005)
                if self.hdd.getIndex() == 2:            #CF
                        print "not a good idea!"
                        self.session.open(MessageBox, "not a good idea - this will kill our rootfs!")
                if self.hdd.getIndex() == 2:            #CF
                        print "not a good idea!"
                        self.session.open(MessageBox, "not a good idea - this will kill our rootfs!")
@@ -49,5 +50,3 @@ class HarddiskSelection(Screen):
        def okbuttonClick(self):
                selection = self["hddlist"].getCurrent()
                self.session.open(HarddiskSetup, selection[1])
        def okbuttonClick(self):
                selection = self["hddlist"].getCurrent()
                self.session.open(HarddiskSetup, selection[1])
-               print "ok"
-               pass