Hello,
In the QAbstractItemModel Class Reference in the description of the reset() method one can read:
"Use beginResetModel() and endResetModel() instead whenever possible. Use this method only if there is no way to call beginResetModel() before invalidating the model. Otherwise it could lead to unexpected behaviour, especially when used with proxy models."
does it mean, that e.g. deleting some rows from the model I shall do it like this:
...
beginResetModel();
beginRemoveRows(parent, fromIdx, toIdx);
// removing rows
endRemoveRows();
endResetModel();
...
instead of calling:
...
beginRemoveRows(parent, fromIdx, toIdx);
// removing rows
endRemoveRows();
reset();
...
thanks
Bookmarks