Skip to content

Fix proxy model smoke test with Qt6

Volker Krause requested to merge work/qt6-fix-proxy-model-smoketest into master

There is a slight change in behavior, QItemSelectionModel now emits a model change when its source model is deleted. This then results in a model reset from a KSelectionProxyModel in this case. The commented code here suggests that this was somewhat anticipated already.

We however have to prevent the model spy in this case from accessing data of the proxy model, as that doesn't know yet its source model is destroyed. It does handle that case in general, this is only down to the invocation order of slots connected to the destroyed() signal, so I don't think this is the fault of the proxy.

Merge request reports