Don't require parent argument for rowCount in DownloadModel.

This commit is contained in:
Florian Bruhin 2014-06-13 20:18:42 +02:00
parent 47c1908da2
commit ba1f8e3764

View File

@ -90,7 +90,7 @@ class DownloadModel(QAbstractListModel):
The default would be Qt.ItemIsEnabled | Qt.ItemIsSelectable.""" The default would be Qt.ItemIsEnabled | Qt.ItemIsSelectable."""
return Qt.ItemIsEnabled return Qt.ItemIsEnabled
def rowCount(self, parent): def rowCount(self, parent=QModelIndex()):
"""Get count of active downloads.""" """Get count of active downloads."""
if parent.isValid(): if parent.isValid():
# We don't have children # We don't have children