oc-folder: Flags are now used in indexing db when deleting a msg

Unregistering the URL in indexing db accordingly to the flags (SOFT or HARD)
oc-folder: Make deleted items synched when shared

By keeping mid on moving messages by soft deleting and
only if srcMid is different from targetMid.

This makes restore/shared deleted items work.

It also requires to do the following to work smoothly:

* Do not add soft-deleted messages in ensureIDsForChildKeys
* Return soft-deleted messages on getDeletedFMIDs
* Do not register a new mid if the URL is matched with soft deleted messages
oc-folder: Uniform call to deleteMessageWithMID

To make sure flags argument is used accordingly with the specs
and not working by chance.
Merge branch 'master' into ejhernandez/keep-fmid-on-soft-deleted-messages
Merge pull request #51 from Zentyal/ejhernandez/keep-fmid-on-soft-deleted-messages

Sync deleted appointments in shared calendars