fix bcall to to new behavior of do(), and fix QtDo too, and all Qt applications...
This commit is contained in:
parent
7339258978
commit
b1f20b5489
16 changed files with 222 additions and 250 deletions
|
|
@ -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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue