-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/128398/
-----------------------------------------------------------

Review request for KDE Frameworks, Stephen  Kelly and Stephen Kelly.


Repository: kitemmodels


Description
-------

KDescendantsProxyModel currently does not reset its internal data when a (new) 
source model is set.

Not sure the provided patch is the most correct one, but it works with the 
current unit tests and for the use case where this bug was hit.
I am still confused why 
`KDescendantsProxyModelPrivate::synchronousMappingRefresh()` loops over `while 
(!m_pendingParents.isEmpty())` on calling `processPendingParents();` while 
`KDescendantsProxyModelPrivate::scheduleProcessPendingParents()` does not.
Especially when the `KDescendantsProxyModelPrivate::sourceModelReset()` handler 
also only calls the latter.
The sourceModelReset handler should be surely similar to what is done on 
setting a new source model, so the patch for now copies that code. But from 
what I understood by reading the code both of them should rather do a full loop 
perhaps?

And `m_relayouting` should get a better name now, but no idea yet what would be 
nice.

I have yet to grasp the proxymodeltest system to also write a matching unit 
test, any proposal where I should start?


Diffs
-----

  src/kdescendantsproxymodel.cpp 477cd96 

Diff: https://git.reviewboard.kde.org/r/128398/diff/


Testing
-------

Existing kitemmodels unit tests still pass.


Thanks,

Friedrich W. H. Kossebau

_______________________________________________
Kde-frameworks-devel mailing list
Kde-frameworks-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-frameworks-devel

Reply via email to