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

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

Issue 8332023: Add support for temporarily disabling sync. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Simplified startup condition for sync 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 4b48d05230bc0ced2537a1235d930aea6621eed8..cca9a81bbe85525252132c7150006345edb78b35 100644
--- a/chrome/browser/sync/profile_sync_service.h
+++ b/chrome/browser/sync/profile_sync_service.h
@@ -480,6 +480,12 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
SigninManager* signin() { return signin_.get(); }
const std::string& cros_user() const { return cros_user_; }
+ // Stops the sync backend and sets the flag for suppressing sync startup.
+ virtual void StopSyncAndSuppressStartUp();
akalin 2011/10/26 18:53:09 Does this need to be virtual? What do you think a
+
+ // Resets the flag for suppressing sync startup and starts the sync backend.
+ virtual void DisableSyncSuppressionAndStartUpSync();
akalin 2011/10/26 18:53:09 Does this need to be virtual? What do you think a
+
// Marks all currently registered types as "acknowledged" so we won't prompt
// the user about them any more.
void AcknowledgeSyncedTypes();
@@ -541,6 +547,10 @@ class ProfileSyncService : public browser_sync::SyncFrontend,
friend class ProfileSyncServiceForWizardTest;
FRIEND_TEST_ALL_PREFIXES(ProfileSyncServiceTest, InitialState);
+ // Starts up sync. Called from Initialize() and
+ // DisableSyncSuppressionAndStartUpSync().
+ void StartUpIfNotSuppressed();
akalin 2011/10/26 18:53:09 what about just "StartIfNotSuppressed()" or maybe
+
// Called when we've determined that we don't need a passphrase (either
// because OnPassphraseAccepted() was called, or because we've gotten a
// OnPassphraseRequired() but no data types are enabled).
« no previous file with comments | « no previous file | chrome/browser/sync/profile_sync_service.cc » ('j') | chrome/browser/sync/profile_sync_service.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698