Hi guys,
I was told that if you want to update the model of a widget, you need do it in QT thread, means you need emit a signal and update model in slot. Is that true?
The problem I faced is I change a tree view's model in a thread, but during I updating the model, QT invoke some draw process.
Because the model is deleted, some value is not available, some index is incorrect, then GUI crashed.
Then I found some function "beginResetModel", "endResetModel". I put them when I update the model.
Some times the QT still call draw process and crash the GUI.
Any comments?
Bookmarks