start scan on execBegin to fix missing self.scan when window was non-execing
[enigma2.git] / lib / python / Components / ServiceScan.py
index 575c030..93af4e6 100644 (file)
@@ -56,8 +56,6 @@ class ServiceScan:
                self.scanList = scanList
                self.run = 0
                
-               self.doRun()
-               
        def doRun(self):
                self.scan = eComponentScan()
                
@@ -72,12 +70,14 @@ class ServiceScan:
        def updatePass(self):
                size = len(self.scanList)
                if size > 1:
-                       self.passNumber.setText(_("pass") + " " + str(self.run + 1) + "/" + str(size) + " (" + _("NIM") + " " + str(self.scanList[self.run]["feid"]) + ")")
+                       self.passNumber.setText(_("pass") + " " + str(self.run + 1) + "/" + str(size) + " (" + _("Tuner") + " " + str(self.scanList[self.run]["feid"]) + ")")
                
        def execBegin(self):
+               self.doRun()
                self.updatePass()
                self.scan.statusChanged.get().append(self.scanStatusChanged)
                self.scan.newService.get().append(self.newService)
+               self.servicelist.clear()
                self.state = self.Running
                err = self.scan.start(self.feid, self.flags)
                if err:
@@ -100,3 +100,6 @@ class ServiceScan:
        def newService(self):
                newServiceName = self.scan.getLastServiceName()
                self.servicelist.addItem(newServiceName)
+
+       def destroy(self):
+               pass