diff options
author | dantasse@chromium.org <dantasse@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-24 21:35:47 +0000 |
---|---|---|
committer | dantasse@chromium.org <dantasse@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-06-24 21:35:47 +0000 |
commit | fb129a38e3f5148fd564a9df0132a4acbbd01ddb (patch) | |
tree | 6762c56969b132d3f07ccfa3067891e311dc6935 /chrome/browser/sync/sync_setup_flow.h | |
parent | 6c73dd61bc320f9f2df7ade207d3aed1d99c8d81 (diff) | |
download | chromium_src-fb129a38e3f5148fd564a9df0132a4acbbd01ddb.zip chromium_src-fb129a38e3f5148fd564a9df0132a4acbbd01ddb.tar.gz chromium_src-fb129a38e3f5148fd564a9df0132a4acbbd01ddb.tar.bz2 |
New HTML Sync Setup UI! This paves the way for the Passphrase UI. (coming soon...)
Old flow:
- type username/password. wait for Gaia auth and initial sync (with throbber)
- success! or error.
New flow:
- type username/password. wait for Gaia auth. (with throbber)
- error, or choose your datatypes. you can choose "keep everything synced", which will sync all present and future datatypes, or you can pick one by one.
- wait for initial sync (with throbber)
- success! or error, which brings you back to the gaia auth screen.
Smaller details:
- removed the Customize button from gaia_login.html; further removal of the old native Customize dialog to follow.
- added a logging statement to log if you cancel from the Choose Data Types screen.
- added a pref to the profile for whether you want to "keep everything synced" or choose one by one.
- added a couple more strings. Not final yet, I don't think.
BUG=45869
TEST=Exercise all the different paths through the login flow.
Review URL: http://codereview.chromium.org/2851012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50774 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync/sync_setup_flow.h')
-rw-r--r-- | chrome/browser/sync/sync_setup_flow.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/chrome/browser/sync/sync_setup_flow.h b/chrome/browser/sync/sync_setup_flow.h index b7dfe24..dcc7fe7 100644 --- a/chrome/browser/sync/sync_setup_flow.h +++ b/chrome/browser/sync/sync_setup_flow.h @@ -47,6 +47,11 @@ class SyncSetupFlow : public HtmlDialogUIDelegate { const ProfileSyncService* service, DictionaryValue* args); + // Fills |args| with "user" and "error" arguments by querying |service|. + static void GetArgsForChooseDataTypes( + ProfileSyncService* service, + DictionaryValue* args); + // Triggers a state machine transition to advance_state. void Advance(SyncSetupWizard::State advance_state); @@ -127,8 +132,14 @@ class SyncSetupFlow : public HtmlDialogUIDelegate { service_->OnUserSubmittedAuth(username, password, captcha); } + void OnUserChoseDataTypes(bool sync_everything, + syncable::ModelTypeSet& chosen_types) { + service_->OnUserChoseDatatypes(sync_everything, chosen_types); + } + private: FRIEND_TEST_ALL_PREFIXES(SyncSetupWizardTest, InitialStepLogin); + FRIEND_TEST_ALL_PREFIXES(SyncSetupWizardTest, ChooseDataTypesSetsPrefs); FRIEND_TEST_ALL_PREFIXES(SyncSetupWizardTest, InitialStepMergeAndSync); FRIEND_TEST_ALL_PREFIXES(SyncSetupWizardTest, DialogCancelled); FRIEND_TEST_ALL_PREFIXES(SyncSetupWizardTest, InvalidTransitions); @@ -204,12 +215,14 @@ class FlowHandler : public DOMMessageHandler { void ClickCustomizeOk(const Value* value); void ClickCustomizeCancel(const Value* value); void HandleSubmitAuth(const Value* value); + void HandleChooseDataTypes(const Value* value); void HandleSubmitMergeAndSync(const Value* value); // These functions control which part of the HTML is visible. void ShowGaiaLogin(const DictionaryValue& args); void ShowGaiaSuccessAndClose(); void ShowGaiaSuccessAndSettingUp(); + void ShowChooseDataTypes(const DictionaryValue& args); void ShowSetupDone(const std::wstring& user); void ShowFirstTimeDone(const std::wstring& user); |