Remove unneeded 'except RuntimeError'
This commit is contained in:
parent
794df11b01
commit
15ce2746eb
@ -119,10 +119,7 @@ class DownloadView(QListView):
|
||||
|
||||
def sizeHint(self):
|
||||
"""Return sizeHint based on the view contents."""
|
||||
try:
|
||||
idx = self.model().last_index()
|
||||
except RuntimeError:
|
||||
pass
|
||||
idx = self.model().last_index()
|
||||
height = self.visualRect(idx).bottom()
|
||||
if height != -1:
|
||||
size = QSize(0, height + 2)
|
||||
|
Loading…
Reference in New Issue
Block a user