Moved all the encryption stuff to the SQLiteVFS

In another step to complete our own SQLiteVFS, the coded that
encrypt/decrypt the database has been moved from StorageManager to the
VFS.

It was required to adapt some APIs and make the call to gpgme_wait in a
blocker way, due it's required to end the encryption before to close the
application.

See Bug #659500 - Prevent the unencrypted database from hitting the disk
https://bugzilla.gnome.org/show_bug.cgi?id=659500