fix bcall to to new behavior of do(), and fix QtDo too, and all Qt applications...

This commit is contained in:
Romain Bignon 2014-10-10 17:34:48 +02:00
commit b1f20b5489
16 changed files with 222 additions and 250 deletions

View file

@ -63,13 +63,15 @@ class QueryDialog(QDialog):
self.ui.cityEdit.clear()
self.ui.cityEdit.setEnabled(False)
self.search_process = QtDo(self.weboob, self.addResult)
self.search_process = QtDo(self.weboob, self.addResult, fb=self.addResultEnd)
self.search_process.do('search_city', pattern)
def addResult(self, backend, city):
if not backend or not city:
self.search_process = None
self.ui.cityEdit.setEnabled(True)
def addResultEnd(self):
self.search_process = None
self.ui.cityEdit.setEnabled(True)
def addResult(self, city):
if not city:
return
item = self.buildCityItem(city)
self.ui.resultsList.addItem(item)