I have same issue, I think this is a bug.
Workaround for this is to use selectionChanged(QItemSelection,QItemSelection) instead of currentRowChanged(QModelIndex,QModelIndex) and use next code:
void YourClass::selectionChangedSlot(const QItemSelection& selection, const QItemSelection&)
{
QModelIndexList selected = selection.indexes();
int row = selected.size() ? selected.first().row() : -1;
...
}
void YourClass::selectionChangedSlot(const QItemSelection& selection, const QItemSelection&)
{
QModelIndexList selected = selection.indexes();
int row = selected.size() ? selected.first().row() : -1;
...
}
To copy to clipboard, switch view to plain text mode
Bookmarks