[Kde-pim] EntityTreeModel doesn't handle setData(Item) calls in quick succession

David Jarvie djarvie at kde.org
Sat Sep 11 16:34:55 BST 2010


When successive calls are made quickly to EntityTreeModel::setData(..., ItemRole, ...) for the same Akonadi Item (and same model index), conflicts occur (the conflict resolve dialog appears). This seems to be because the Item revision number can be the same for two calls if the first ItemModifyJob has not completed when the second setData() is called. The symptom also occurs when Item attributes are modified (without a call to setData()).

I suspect that it is necessary for EntityTreeModel to implement a queuing system for ItemModifyJob, which waits for one job to complete before the next is created. In the result slot for the job, the Item revision number in the next queued job would need to be updated to the new value before the job is scheduled.

-- 
David Jarvie.
KDE developer.
KAlarm author -- http://www.astrojar.org.uk/kalarm
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20100911/b9fdb06a/attachment.sig>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list