D5667: delay filtering to the point when a new item gets its remote id

Daniel Vrátil noreply at phabricator.kde.org
Sun Apr 30 23:16:20 BST 2017


dvratil requested changes to this revision.
dvratil added a comment.
This revision now requires changes to proceed.


  Looks good, just some minor details.
  
  Regarding the parent collection being passed separately to itemAdded, I believe that's because of the semantics of the slot. When item is created, it technically does not belong to a collection yet (because the Resource did not store it there remotely yet).
  
  Preferably you should pass the collection to filterItem() as a second argument, I'm not sure if you can rely on Item::parentCollection() in the itemAdded slot. You can use Item::parentCollection() in slotItemChanged() safely though.
  
  For the itemMonitor, you should ensure via ItemFetchScope that the remote identifiers and ancestor are retrieved (the ancestor Retrieval policy should correspond with the the policy of the Resource's ChabgeRecorder ancestor policy).

REPOSITORY
  R206 KMail

REVISION DETAIL
  https://phabricator.kde.org/D5667

To: mkoller, dvratil, mlaurent
Cc: #kde_pim, dvasin, ach, winterz, vkrause, mlaurent, knauss, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20170430/70c9a601/attachment.html>


More information about the kde-pim mailing list