| Index: chrome/browser/sync/profile_sync_service.h
|
| diff --git a/chrome/browser/sync/profile_sync_service.h b/chrome/browser/sync/profile_sync_service.h
|
| index ec9ce6b42d1dcbae09a1c801c534273c4f8bdc58..f75a8e2ce69f7e51e70bc580e6f7d1db58b98a12 100644
|
| --- a/chrome/browser/sync/profile_sync_service.h
|
| +++ b/chrome/browser/sync/profile_sync_service.h
|
| @@ -190,6 +190,8 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
|
| virtual void OnClearServerDataSucceeded();
|
| virtual void OnPassphraseRequired(bool for_decryption);
|
| virtual void OnPassphraseAccepted();
|
| + virtual void OnEncryptionComplete(
|
| + const syncable::ModelTypeSet& encrypted_types);
|
|
|
| // Called when a user enters credentials through UI.
|
| virtual void OnUserSubmittedAuth(const std::string& username,
|
| @@ -434,6 +436,19 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
|
| bool is_explicit,
|
| bool is_creation);
|
|
|
| + // Changes the set of datatypes that require encryption. This affects all
|
| + // machines synced to this account and all data belonging to the specified
|
| + // types. |encrypted_types| must be a subset of the active datatypes.
|
| + // Note that this is an asynchronous operation (the encryption of data is
|
| + // performed on SyncBackendHost's core thread) and may not have an immediate
|
| + // effect.
|
| + virtual void EncryptDataTypes(
|
| + const syncable::ModelTypeSet& encrypted_types);
|
| +
|
| + // Get the currently encrypted data types.
|
| + virtual void GetEncryptedDataTypes(
|
| + syncable::ModelTypeSet* encrypted_types) const;
|
| +
|
| // Returns whether processing changes is allowed. Check this before doing
|
| // any model-modifying operations.
|
| bool ShouldPushChanges();
|
| @@ -640,6 +655,10 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
|
| // is reworked to allow one-shot commands like clearing server data.
|
| base::OneShotTimer<ProfileSyncService> clear_server_data_timer_;
|
|
|
| + // The set of encrypted types. This is updated whenever datatypes are
|
| + // encrypted through the OnEncryptionComplete callback of SyncFrontend.
|
| + syncable::ModelTypeSet encrypted_types_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(ProfileSyncService);
|
| };
|
|
|
|
|