Skip to content

Commit

Permalink
[processing] handle loading empty models in modeler (fix #8153)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbruy committed Aug 28, 2013
1 parent bc63fcd commit b0ed8ed
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/plugins/processing/modeler/ModelerDialog.py
Expand Up @@ -219,7 +219,8 @@ def openModel(self):
self.textGroup.setText(alg.group)
self.textName.setText(alg.name)
self.repaintModel()
self.view.ensureVisible(self.scene.getLastAlgorithmItem())
if self.scene.getLastAlgorithmItem():
self.view.ensureVisible(self.scene.getLastAlgorithmItem())
self.view.centerOn(0,0)
except WrongModelException, e:
QMessageBox.critical(self,
Expand Down

0 comments on commit b0ed8ed

Please sign in to comment.