Skip to content

Commit

Permalink
[processing] fix refreshing of the toolbox after downloading scripts/…
Browse files Browse the repository at this point in the history
…models
  • Loading branch information
alexbruy committed Feb 17, 2016
1 parent bfcf92f commit 9bf3b2e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions python/plugins/processing/gui/GetScriptsAndModels.py
Expand Up @@ -168,6 +168,9 @@ def grabHTTP(self, url, loadFunction, arguments=None):
else:
reply.finished.connect(partial(loadFunction, reply))

while not reply.isFinished():
QCoreApplication.processEvents()

def populateTree(self):
self.uptodateItem = QTreeWidgetItem()
self.uptodateItem.setText(0, self.tr('Installed'))
Expand Down Expand Up @@ -245,7 +248,7 @@ def getTreeBranchForState(self, filename, version):
return self.uptodateItem

def cancelPressed(self):
self.close()
super(GetScriptsAndModelsDialog, self).reject()

def storeFile(self, reply, filename):
"""store a script/model that has been downloaded"""
Expand Down Expand Up @@ -302,7 +305,7 @@ def okPressed(self):
os.remove(path)

self.updateToolbox = len(toDownload) + len(toDelete) > 0
self.close()
super(GetScriptsAndModelsDialog, self).accept()


class TreeItem(QTreeWidgetItem):
Expand Down

0 comments on commit 9bf3b2e

Please sign in to comment.