Re: QSortFilterProxyModel Crashing with QTableView when Row Changed
Let me preface my comments by stating that I have never attempted what you appear to be doing, which is having multiple QSortFilterProxyModel's chained/used. Not saying it shouldn't work, but right off the bat it seems odd to me...
Is there a reason your OpenJobSortFilterProxyModel isn't used for both the sorting and filtering you're trying to achieve by instead attempting to use using multiple QSortFilterProxyModel's?
I believe because you're using multiple views with multiple QSortFilterProxyFilter's that all have the same underlying data model, that is why your app is crashing. I would suggest that you simplify and once you get that working, and only then add in complexity.
For example, take one of your views, use one QSortFilterProxyFilter subclass for the QSqlModel data model. Make that work without failing, then try to add in additional functionality.
Good luck.
I write the best type of code possible, code that I want to write, not code that someone tells me to write!
Bookmarks