Return with invalid index

This commit is contained in:
Florian Bruhin 2016-08-02 11:56:34 +02:00
parent b8aeb9f80e
commit b17296db0d

View File

@ -199,6 +199,9 @@ class CompletionView(QTreeView):
return return
idx = self._next_idx(prev) idx = self._next_idx(prev)
if not idx.isValid():
return
selmodel.setCurrentIndex( selmodel.setCurrentIndex(
idx, QItemSelectionModel.ClearAndSelect | QItemSelectionModel.Rows) idx, QItemSelectionModel.ClearAndSelect | QItemSelectionModel.Rows)