Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(592)

Unified Diff: chrome/browser/sync/profile_sync_service.h

Issue 8356026: [Sync] Cache encrypted types info in ProfileSyncService (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert to synchronous notifications Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 20214e1409e0311f57a9c0ef55b09b1f8092dffe..5d5154f077b4018c1bf494204de69408140f4fdc 100644
--- a/chrome/browser/sync/profile_sync_service.h
+++ b/chrome/browser/sync/profile_sync_service.h
@@ -209,8 +209,10 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
virtual void OnPassphraseRequired(
sync_api::PassphraseRequiredReason reason) OVERRIDE;
virtual void OnPassphraseAccepted() OVERRIDE;
- virtual void OnEncryptionComplete(
- const syncable::ModelTypeSet& encrypted_types) OVERRIDE;
+ virtual void OnEncryptedTypesChanged(
+ const syncable::ModelTypeSet& enncrypted_types,
+ bool encrypt_everything) OVERRIDE;
+ virtual void OnEncryptionComplete() OVERRIDE;
virtual void OnMigrationNeededForTypes(
const syncable::ModelTypeSet& types) OVERRIDE;
virtual void OnDataTypesChanged(
@@ -670,6 +672,12 @@ 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 and whether or not we want to encrypt
+ // everything. Initialized on OnBackendInitialized and updated by
Nicolas Zea 2011/10/21 14:29:07 Perhaps include a comment that the Cryptographer::
akalin 2011/10/22 03:28:38 Done.
+ // OnEncryptionComplete.
+ syncable::ModelTypeSet encrypted_types_;
+ bool encrypt_everything_;
+
// Whether we're waiting for an attempt to encryption all sync data to
// complete. We track this at this layer in order to allow the user to cancel
// if they e.g. don't remember their explicit passphrase.

Powered by Google App Engine
This is Rietveld 408576698