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

Unified Diff: chrome/browser/sync/glue/sync_backend_host.h

Issue 6380004: [Sync] Tidy up SyncBackendHost interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix windows compile Created 9 years, 11 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/glue/sync_backend_host.h
diff --git a/chrome/browser/sync/glue/sync_backend_host.h b/chrome/browser/sync/glue/sync_backend_host.h
index 3543a4fa432f35953adcaf87fc93f673c36c89d3..cd418aa1a4a54bf5a8180b6a3e3b7d9cac3669b9 100644
--- a/chrome/browser/sync/glue/sync_backend_host.h
+++ b/chrome/browser/sync/glue/sync_backend_host.h
@@ -71,6 +71,19 @@ class SyncFrontend {
virtual void OnClearServerDataSucceeded() = 0;
virtual void OnClearServerDataFailed() = 0;
+ // The syncer requires a passphrase to decrypt sensitive
+ // updates. This is called when the first sensitive data type is
+ // setup by the user as well as anytime any the passphrase is
+ // changed in another synced client. if
+ // |passphrase_required_for_decryption| is false, the passphrase is
+ // required only for encryption.
+ virtual void OnPassphraseRequired(bool for_decryption) = 0;
+
+ // Called when the passphrase provided by the user is
+ // accepted. After this is called, updates to sensitive nodes are
+ // encrypted using the accepted passphrase.
+ virtual void OnPassphraseAccepted() = 0;
tim (not reviewing) 2011/01/19 20:42:53 sweet, so you gonna write a sync_backend_host_unit
+
protected:
// Don't delete through SyncFrontend interface.
virtual ~SyncFrontend() {
@@ -94,10 +107,7 @@ class SyncBackendHost : public browser_sync::ModelSafeWorkerRegistrar {
// Create a SyncBackendHost with a reference to the |frontend| that it serves
// and communicates to via the SyncFrontend interface (on the same thread
// it used to call the constructor).
- SyncBackendHost(SyncFrontend* frontend,
- Profile* profile,
- const FilePath& profile_path,
- const DataTypeController::TypeMap& data_type_controllers);
+ SyncBackendHost(SyncFrontend* frontend, Profile* profile);
// For testing.
// TODO(skrul): Extract an interface so this is not needed.
SyncBackendHost();
@@ -139,8 +149,10 @@ class SyncBackendHost : public browser_sync::ModelSafeWorkerRegistrar {
// The ready_task will be run when all of the requested data types
// are up-to-date and ready for activation. The task will cancelled
// upon shutdown. The method takes ownership of the task pointer.
- virtual void ConfigureDataTypes(const syncable::ModelTypeSet& types,
- CancelableTask* ready_task);
+ virtual void ConfigureDataTypes(
+ const DataTypeController::TypeMap& data_type_controllers,
+ const syncable::ModelTypeSet& types,
+ CancelableTask* ready_task);
syncable::AutofillMigrationState
GetAutofillMigrationState();
@@ -506,9 +518,6 @@ class SyncBackendHost : public browser_sync::ModelSafeWorkerRegistrar {
// Path of the folder that stores the sync data files.
FilePath sync_data_folder_path_;
- // List of registered data type controllers.
- DataTypeController::TypeMap data_type_controllers_;
-
// A task that should be called once data type configuration is
// complete.
scoped_ptr<CancelableTask> configure_ready_task_;

Powered by Google App Engine
This is Rietveld 408576698