diff options
author | rlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-21 02:39:43 +0000 |
---|---|---|
committer | rlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-21 02:39:43 +0000 |
commit | d550ce0e73f31f84efd7be83309e913a97ca60e5 (patch) | |
tree | 81b25fd9c4f5d49d8a44c7d40b7187fd70ed180f /chrome/browser/sync/internal_api/sync_manager.h | |
parent | 6652074712f84591150721953f6ed8049145256e (diff) | |
download | chromium_src-d550ce0e73f31f84efd7be83309e913a97ca60e5.zip chromium_src-d550ce0e73f31f84efd7be83309e913a97ca60e5.tar.gz chromium_src-d550ce0e73f31f84efd7be83309e913a97ca60e5.tar.bz2 |
Change definition of about:sync summary
The old syner status definition has outlived its usefulness. After a
series of refactorings in the status summary reporting classes, it
provides practically no useful and non-redundant information.
The new syncer status is based on the information available to the
ProfileSyncService. It attempts to indicate what level of
initialization the sync service has reached, and therefore what sort of
service a user ought to expect from it.
This has a significant impact on some tests, which have come to rely on
the summary as a means of inspecting internal state. I consider this to
be a bad idea, since most of these tests should be testing behaviour,
not internal state. In an attempt to discourage tests from relying on
this summary in the future, the summary is now available only as an
std::string.
This change breaks the python functional sync tests. However, these
test were already broken prior to this change. Fixing and re-enabling
these tests is a job best left ot a future CL.
BUG=112229,98346
TEST=
Review URL: http://codereview.chromium.org/9724012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@127886 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync/internal_api/sync_manager.h')
-rw-r--r-- | chrome/browser/sync/internal_api/sync_manager.h | 31 |
1 files changed, 1 insertions, 30 deletions
diff --git a/chrome/browser/sync/internal_api/sync_manager.h b/chrome/browser/sync/internal_api/sync_manager.h index 31797e3..c9d45b8 100644 --- a/chrome/browser/sync/internal_api/sync_manager.h +++ b/chrome/browser/sync/internal_api/sync_manager.h @@ -95,35 +95,9 @@ class SyncManager { // Status encapsulates detailed state about the internals of the SyncManager. struct Status { - // Summary is a distilled set of important information that the end-user may - // wish to be informed about (through UI, for example). Note that if a - // summary state requires user interaction (such as auth failures), more - // detailed information may be contained in additional status fields. - enum Summary { - // The internal instance is in an unrecognizable state. This should not - // happen. - INVALID = 0, - // Can't connect to server, but there are no pending changes in - // our local cache. - OFFLINE, - // Can't connect to server, and there are pending changes in our - // local cache. - OFFLINE_UNSYNCED, - // Connected and syncing. - SYNCING, - // Connected, no pending changes. - READY, - // Can't connect to server, and we haven't completed the initial - // sync yet. So there's nothing we can do but wait for the server. - OFFLINE_UNUSABLE, - - SUMMARY_STATUS_COUNT, - }; - Status(); ~Status(); - Summary summary; bool notifications_enabled; // True only if subscribed for notifications. // Notifications counters updated by the actions in synapi. @@ -559,10 +533,7 @@ class SyncManager { // potentially dereference garbage. void RemoveObserver(Observer* observer); - // Status-related getters. Typically GetStatusSummary will suffice, but - // GetDetailedSyncStatus can be useful for gathering debug-level details of - // the internals of the sync engine. May be called on any thread. - Status::Summary GetStatusSummary() const; + // Status-related getter. May be called on any thread. Status GetDetailedStatus() const; // Whether or not the Nigori node is encrypted using an explicit passphrase. |