OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/sync/sync_setup_wizard.h" | 5 #include "chrome/browser/sync/sync_setup_wizard.h" |
6 | 6 |
7 #include "base/memory/singleton.h" | 7 #include "base/memory/singleton.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "chrome/browser/google/google_util.h" | 9 #include "chrome/browser/google/google_util.h" |
10 #include "chrome/browser/prefs/pref_service.h" | 10 #include "chrome/browser/prefs/pref_service.h" |
11 #include "chrome/browser/profiles/profile.h" | 11 #include "chrome/browser/profiles/profile.h" |
12 #include "chrome/browser/sync/profile_sync_service.h" | 12 #include "chrome/browser/sync/profile_sync_service.h" |
13 #include "chrome/browser/sync/sync_setup_flow.h" | 13 #include "chrome/browser/sync/sync_setup_flow.h" |
14 #include "chrome/browser/ui/webui/chrome_url_data_manager.h" | 14 #include "chrome/browser/ui/webui/chrome_url_data_manager.h" |
15 #include "chrome/common/jstemplate_builder.h" | 15 #include "chrome/common/jstemplate_builder.h" |
16 #include "chrome/common/pref_names.h" | 16 #include "chrome/common/pref_names.h" |
17 #include "chrome/common/url_constants.h" | 17 #include "chrome/common/url_constants.h" |
18 #include "content/browser/browser_thread.h" | 18 #include "content/browser/browser_thread.h" |
19 #include "googleurl/src/gurl.h" | 19 #include "googleurl/src/gurl.h" |
20 #include "grit/app_resources.h" | 20 #include "grit/app_resources.h" |
21 #include "grit/browser_resources.h" | 21 #include "grit/browser_resources.h" |
22 #include "grit/chromium_strings.h" | 22 #include "grit/chromium_strings.h" |
23 #include "grit/generated_resources.h" | 23 #include "grit/generated_resources.h" |
24 #include "grit/locale_settings.h" | 24 #include "grit/locale_settings.h" |
25 #include "ui/base/resource/resource_bundle.h" | 25 #include "ui/base/resource/resource_bundle.h" |
26 | 26 |
27 namespace { | 27 namespace { |
28 | 28 |
| 29 const char* kInvalidPasswordHelpUrl = |
| 30 "https://www.google.com/support/accounts/bin/answer.py?ctx=ch&answer=27444"; |
| 31 const char* kCanNotAccessAccountUrl = |
| 32 "https://www.google.com/support/accounts/bin/answer.py?answer=48598"; |
| 33 #if defined(OS_CHROMEOS) |
| 34 const char* kEncryptionHelpUrl = |
| 35 "https://www.google.com/support/chromeos/bin/answer.py?answer=1181035"; |
| 36 #else |
| 37 const char* kEncryptionHelpUrl = |
| 38 "https://www.google.com/support/chrome/bin/answer.py?answer=1181035"; |
| 39 #endif |
| 40 const char* kCreateNewAccountUrl = |
| 41 "https://www.google.com/accounts/NewAccount?service=chromiumsync"; |
| 42 const char* kSyncHelpUrl = |
| 43 "https://www.google.com/support/chrome/bin/answer.py?hl=en&answer=165139"; |
| 44 |
29 // Utility method to keep dictionary population code streamlined. | 45 // Utility method to keep dictionary population code streamlined. |
30 void AddString(DictionaryValue* dictionary, | 46 void AddString(DictionaryValue* dictionary, |
31 const std::string& key, | 47 const std::string& key, |
32 int resource_id) { | 48 int resource_id) { |
33 dictionary->SetString(key, l10n_util::GetStringUTF16(resource_id)); | 49 dictionary->SetString(key, l10n_util::GetStringUTF16(resource_id)); |
34 } | 50 } |
35 | 51 |
36 } | 52 } |
37 | 53 |
38 class SyncResourcesSource : public ChromeURLDataManager::DataSource { | 54 class SyncResourcesSource : public ChromeURLDataManager::DataSource { |
39 public: | 55 public: |
40 SyncResourcesSource() | 56 SyncResourcesSource() |
41 : DataSource(chrome::kChromeUISyncResourcesHost, MessageLoop::current()) { | 57 : DataSource(chrome::kChromeUISyncResourcesHost, MessageLoop::current()) { |
42 } | 58 } |
43 | 59 |
44 virtual void StartDataRequest(const std::string& path, | 60 virtual void StartDataRequest(const std::string& path, |
45 bool is_incognito, | 61 bool is_incognito, |
46 int request_id); | 62 int request_id); |
47 | 63 |
48 virtual std::string GetMimeType(const std::string& path) const { | 64 virtual std::string GetMimeType(const std::string& path) const { |
49 return "text/html"; | 65 return "text/html"; |
50 } | 66 } |
51 | 67 |
52 static const char* kInvalidPasswordHelpUrl; | |
53 static const char* kCanNotAccessAccountUrl; | |
54 static const char* kCreateNewAccountUrl; | |
55 static const char* kEncryptionHelpUrl; | |
56 | |
57 private: | 68 private: |
58 virtual ~SyncResourcesSource() {} | 69 virtual ~SyncResourcesSource() {} |
59 | 70 |
60 // Takes a string containing an URL and returns an URL containing a CGI | 71 // Takes a string containing an URL and returns an URL containing a CGI |
61 // parameter of the form "&hl=xy" where 'xy' is the language code of the | 72 // parameter of the form "&hl=xy" where 'xy' is the language code of the |
62 // current locale. | 73 // current locale. |
63 std::string GetLocalizedUrl(const std::string& url) const; | 74 std::string GetLocalizedUrl(const std::string& url) const; |
64 | 75 |
65 DISALLOW_COPY_AND_ASSIGN(SyncResourcesSource); | 76 DISALLOW_COPY_AND_ASSIGN(SyncResourcesSource); |
66 }; | 77 }; |
67 | 78 |
68 const char* SyncResourcesSource::kInvalidPasswordHelpUrl = | 79 |
69 "https://www.google.com/support/accounts/bin/answer.py?ctx=ch&answer=27444"; | |
70 const char* SyncResourcesSource::kCanNotAccessAccountUrl = | |
71 "https://www.google.com/support/accounts/bin/answer.py?answer=48598"; | |
72 #if defined(OS_CHROMEOS) | |
73 const char* SyncResourcesSource::kEncryptionHelpUrl = | |
74 "https://www.google.com/support/chromeos/bin/answer.py?answer=1181035"; | |
75 #else | |
76 const char* SyncResourcesSource::kEncryptionHelpUrl = | |
77 "https://www.google.com/support/chrome/bin/answer.py?answer=1181035"; | |
78 #endif | |
79 const char* SyncResourcesSource::kCreateNewAccountUrl = | |
80 "https://www.google.com/accounts/NewAccount?service=chromiumsync"; | |
81 | 80 |
82 void SyncResourcesSource::StartDataRequest(const std::string& path_raw, | 81 void SyncResourcesSource::StartDataRequest(const std::string& path_raw, |
83 bool is_incognito, | 82 bool is_incognito, |
84 int request_id) { | 83 int request_id) { |
85 using l10n_util::GetStringUTF16; | 84 using l10n_util::GetStringUTF16; |
86 using l10n_util::GetStringFUTF16; | 85 using l10n_util::GetStringFUTF16; |
87 | 86 |
88 const char kSyncSetupFlowPath[] = "setup"; | 87 const char kSyncSetupFlowPath[] = "setup"; |
89 const char kSyncGaiaLoginPath[] = "gaialogin"; | 88 const char kSyncGaiaLoginPath[] = "gaialogin"; |
90 const char kSyncConfigurePath[] = "configure"; | 89 const char kSyncConfigurePath[] = "configure"; |
91 const char kSyncPassphrasePath[] = "passphrase"; | 90 const char kSyncPassphrasePath[] = "passphrase"; |
92 const char kSyncFirstPassphrasePath[] = "firstpassphrase"; | 91 const char kSyncFirstPassphrasePath[] = "firstpassphrase"; |
93 const char kSyncSettingUpPath[] = "settingup"; | 92 const char kSyncSettingUpPath[] = "settingup"; |
94 const char kSyncSetupDonePath[] = "setupdone"; | 93 const char kSyncSetupDonePath[] = "setupdone"; |
95 | 94 |
96 std::string response; | 95 std::string response; |
97 DictionaryValue strings; | 96 DictionaryValue strings; |
98 DictionaryValue* dict = &strings; | 97 DictionaryValue* dict = &strings; |
99 int html_resource_id = 0; | 98 int html_resource_id = 0; |
100 if (path_raw == kSyncGaiaLoginPath) { | 99 if (path_raw == kSyncGaiaLoginPath) { |
101 html_resource_id = IDR_GAIA_LOGIN_HTML; | 100 html_resource_id = IDR_GAIA_LOGIN_HTML; |
102 | 101 |
103 // Start by setting the per-locale URLs we show on the setup wizard. | 102 // Start by setting the per-locale URLs we show on the setup wizard. |
104 dict->SetString("invalidpasswordhelpurl", | 103 dict->SetString("invalidpasswordhelpurl", |
105 GetLocalizedUrl(kInvalidPasswordHelpUrl)); | 104 GetLocalizedUrl(kInvalidPasswordHelpUrl)); |
106 dict->SetString("cannotaccessaccounturl", | 105 dict->SetString("cannotaccessaccounturl", |
107 GetLocalizedUrl(kCanNotAccessAccountUrl)); | 106 GetLocalizedUrl(kCanNotAccessAccountUrl)); |
108 dict->SetString("createnewaccounturl", | 107 dict->SetString("createnewaccounturl", |
109 GetLocalizedUrl(kCreateNewAccountUrl)); | 108 GetLocalizedUrl(kCreateNewAccountUrl)); |
| 109 dict->SetString("synchelpurl", |
| 110 GetLocalizedUrl(kSyncHelpUrl)); |
110 AddString(dict, "settingupsync", IDS_SYNC_LOGIN_SETTING_UP_SYNC); | 111 AddString(dict, "settingupsync", IDS_SYNC_LOGIN_SETTING_UP_SYNC); |
111 dict->SetString("introduction", | |
112 GetStringFUTF16(IDS_SYNC_LOGIN_INTRODUCTION, | |
113 GetStringUTF16(IDS_PRODUCT_NAME))); | |
114 AddString(dict, "signinprefix", IDS_SYNC_LOGIN_SIGNIN_PREFIX); | 112 AddString(dict, "signinprefix", IDS_SYNC_LOGIN_SIGNIN_PREFIX); |
115 AddString(dict, "signinsuffix", IDS_SYNC_LOGIN_SIGNIN_SUFFIX); | 113 AddString(dict, "signinsuffix", IDS_SYNC_LOGIN_SIGNIN_SUFFIX); |
116 AddString(dict, "cannotbeblank", IDS_SYNC_CANNOT_BE_BLANK); | 114 AddString(dict, "cannotbeblank", IDS_SYNC_CANNOT_BE_BLANK); |
117 AddString(dict, "emaillabel", IDS_SYNC_LOGIN_EMAIL); | 115 AddString(dict, "emaillabel", IDS_SYNC_LOGIN_EMAIL); |
118 AddString(dict, "passwordlabel", IDS_SYNC_LOGIN_PASSWORD); | 116 AddString(dict, "passwordlabel", IDS_SYNC_LOGIN_PASSWORD); |
119 AddString(dict, "invalidcredentials", IDS_SYNC_INVALID_USER_CREDENTIALS); | 117 AddString(dict, "invalidcredentials", IDS_SYNC_INVALID_USER_CREDENTIALS); |
120 AddString(dict, "signin", IDS_SYNC_SIGNIN); | 118 AddString(dict, "signin", IDS_SYNC_SIGNIN); |
121 AddString(dict, "couldnotconnect", IDS_SYNC_LOGIN_COULD_NOT_CONNECT); | 119 AddString(dict, "couldnotconnect", IDS_SYNC_LOGIN_COULD_NOT_CONNECT); |
122 AddString(dict, "cannotaccessaccount", IDS_SYNC_CANNOT_ACCESS_ACCOUNT); | 120 AddString(dict, "cannotaccessaccount", IDS_SYNC_CANNOT_ACCESS_ACCOUNT); |
123 AddString(dict, "createaccount", IDS_SYNC_CREATE_ACCOUNT); | 121 AddString(dict, "createaccount", IDS_SYNC_CREATE_ACCOUNT); |
124 AddString(dict, "cancel", IDS_CANCEL); | 122 AddString(dict, "cancel", IDS_CANCEL); |
125 AddString(dict, "settingup", IDS_SYNC_LOGIN_SETTING_UP); | 123 AddString(dict, "settingup", IDS_SYNC_LOGIN_SETTING_UP); |
126 AddString(dict, "success", IDS_SYNC_SUCCESS); | 124 AddString(dict, "success", IDS_SYNC_SUCCESS); |
127 AddString(dict, "errorsigningin", IDS_SYNC_ERROR_SIGNING_IN); | 125 AddString(dict, "errorsigningin", IDS_SYNC_ERROR_SIGNING_IN); |
128 AddString(dict, "captchainstructions", IDS_SYNC_GAIA_CAPTCHA_INSTRUCTIONS); | 126 AddString(dict, "captchainstructions", IDS_SYNC_GAIA_CAPTCHA_INSTRUCTIONS); |
129 AddString(dict, "invalidaccesscode", IDS_SYNC_INVALID_ACCESS_CODE_LABEL); | 127 AddString(dict, "invalidaccesscode", IDS_SYNC_INVALID_ACCESS_CODE_LABEL); |
130 AddString(dict, "enteraccesscode", IDS_SYNC_ENTER_ACCESS_CODE_LABEL); | 128 AddString(dict, "enteraccesscode", IDS_SYNC_ENTER_ACCESS_CODE_LABEL); |
131 AddString(dict, "getaccesscodehelp", IDS_SYNC_ACCESS_CODE_HELP_LABEL); | 129 AddString(dict, "getaccesscodehelp", IDS_SYNC_ACCESS_CODE_HELP_LABEL); |
132 AddString(dict, "getaccesscodeurl", IDS_SYNC_GET_ACCESS_CODE_URL); | 130 AddString(dict, "getaccesscodeurl", IDS_SYNC_GET_ACCESS_CODE_URL); |
133 } else if (path_raw == kSyncConfigurePath) { | 131 } else if (path_raw == kSyncConfigurePath) { |
134 html_resource_id = IDR_SYNC_CONFIGURE_HTML; | 132 html_resource_id = IDR_SYNC_CONFIGURE_HTML; |
135 | 133 |
136 AddString(dict, "dataTypes", IDS_SYNC_DATA_TYPES_TAB_NAME); | 134 AddString(dict, "dataTypes", IDS_SYNC_DATA_TYPES_TAB_NAME); |
137 AddString(dict, "encryption", IDS_SYNC_ENCRYPTION_TAB_NAME); | 135 AddString(dict, "encryption", IDS_SYNC_ENCRYPTION_TAB_NAME); |
| 136 AddString( |
| 137 dict, "confirmSyncPreferences", IDS_SYNC_CONFIRM_SYNC_PREFERENCES); |
| 138 AddString(dict, "syncEverything", IDS_SYNC_SYNC_EVERYTHING); |
138 | 139 |
139 // Stuff for the choose data types localized. | 140 // Stuff for the choose data types localized. |
140 AddString(dict, "choosedatatypesheader", IDS_SYNC_CHOOSE_DATATYPES_HEADER); | 141 AddString(dict, "choosedatatypesheader", IDS_SYNC_CHOOSE_DATATYPES_HEADER); |
141 dict->SetString("choosedatatypesinstructions", | 142 dict->SetString("choosedatatypesinstructions", |
142 GetStringFUTF16(IDS_SYNC_CHOOSE_DATATYPES_INSTRUCTIONS, | 143 GetStringFUTF16(IDS_SYNC_CHOOSE_DATATYPES_INSTRUCTIONS, |
143 GetStringUTF16(IDS_PRODUCT_NAME))); | 144 GetStringUTF16(IDS_PRODUCT_NAME))); |
144 AddString(dict, "keepeverythingsynced", IDS_SYNC_EVERYTHING); | 145 AddString(dict, "keepeverythingsynced", IDS_SYNC_EVERYTHING); |
145 AddString(dict, "choosedatatypes", IDS_SYNC_CHOOSE_DATATYPES); | 146 AddString(dict, "choosedatatypes", IDS_SYNC_CHOOSE_DATATYPES); |
146 AddString(dict, "bookmarks", IDS_SYNC_DATATYPE_BOOKMARKS); | 147 AddString(dict, "bookmarks", IDS_SYNC_DATATYPE_BOOKMARKS); |
147 AddString(dict, "preferences", IDS_SYNC_DATATYPE_PREFERENCES); | 148 AddString(dict, "preferences", IDS_SYNC_DATATYPE_PREFERENCES); |
148 AddString(dict, "autofill", IDS_SYNC_DATATYPE_AUTOFILL); | 149 AddString(dict, "autofill", IDS_SYNC_DATATYPE_AUTOFILL); |
149 AddString(dict, "themes", IDS_SYNC_DATATYPE_THEMES); | 150 AddString(dict, "themes", IDS_SYNC_DATATYPE_THEMES); |
150 AddString(dict, "passwords", IDS_SYNC_DATATYPE_PASSWORDS); | 151 AddString(dict, "passwords", IDS_SYNC_DATATYPE_PASSWORDS); |
151 AddString(dict, "extensions", IDS_SYNC_DATATYPE_EXTENSIONS); | 152 AddString(dict, "extensions", IDS_SYNC_DATATYPE_EXTENSIONS); |
152 AddString(dict, "typedurls", IDS_SYNC_DATATYPE_TYPED_URLS); | 153 AddString(dict, "typedurls", IDS_SYNC_DATATYPE_TYPED_URLS); |
153 AddString(dict, "apps", IDS_SYNC_DATATYPE_APPS); | 154 AddString(dict, "apps", IDS_SYNC_DATATYPE_APPS); |
154 AddString(dict, "foreignsessions", IDS_SYNC_DATATYPE_SESSIONS); | 155 AddString(dict, "foreignsessions", IDS_SYNC_DATATYPE_SESSIONS); |
155 AddString(dict, "synczerodatatypeserror", IDS_SYNC_ZERO_DATA_TYPES_ERROR); | 156 AddString(dict, "synczerodatatypeserror", IDS_SYNC_ZERO_DATA_TYPES_ERROR); |
156 AddString(dict, "abortederror", IDS_SYNC_SETUP_ABORTED_BY_PENDING_CLEAR); | 157 AddString(dict, "abortederror", IDS_SYNC_SETUP_ABORTED_BY_PENDING_CLEAR); |
157 | 158 |
158 // Stuff for the encryption tab. | 159 // Stuff for the encryption tab. |
159 dict->SetString("encryptionInstructions", | 160 dict->SetString("encryptionInstructions", |
160 GetStringFUTF16(IDS_SYNC_ENCRYPTION_INSTRUCTIONS, | 161 GetStringFUTF16(IDS_SYNC_ENCRYPTION_INSTRUCTIONS, |
161 GetStringUTF16(IDS_PRODUCT_NAME))); | 162 GetStringUTF16(IDS_PRODUCT_NAME))); |
162 AddString(dict, "encryptAllLabel", IDS_SYNC_ENCRYPT_ALL_LABEL); | 163 AddString(dict, "encryptAllLabel", IDS_SYNC_ENCRYPT_ALL_LABEL); |
163 | 164 AddString( |
| 165 dict, "passphraseSectionTitle", IDS_SYNC_PASSPHRASE_SECTION_TITLE); |
164 AddString(dict, "googleOption", IDS_SYNC_PASSPHRASE_OPT_GOOGLE); | 166 AddString(dict, "googleOption", IDS_SYNC_PASSPHRASE_OPT_GOOGLE); |
165 AddString(dict, "explicitOption", IDS_SYNC_PASSPHRASE_OPT_EXPLICIT); | 167 AddString(dict, "explicitOption", IDS_SYNC_PASSPHRASE_OPT_EXPLICIT); |
166 AddString(dict, "sectionGoogleMessage", IDS_SYNC_PASSPHRASE_MSG_GOOGLE); | 168 AddString(dict, "sectionGoogleMessage", IDS_SYNC_PASSPHRASE_MSG_GOOGLE); |
167 AddString(dict, "sectionExplicitMessage", IDS_SYNC_PASSPHRASE_MSG_EXPLICIT); | 169 AddString(dict, |
| 170 "sectionExplicitMessagePrefix", |
| 171 IDS_SYNC_PASSPHRASE_MSG_EXPLICIT_PREFIX); |
| 172 AddString(dict, |
| 173 "sectionExplicitMessagePostfix", |
| 174 IDS_SYNC_PASSPHRASE_MSG_EXPLICIT_POSTFIX); |
168 AddString(dict, "passphraseLabel", IDS_SYNC_PASSPHRASE_LABEL); | 175 AddString(dict, "passphraseLabel", IDS_SYNC_PASSPHRASE_LABEL); |
169 AddString(dict, "confirmLabel", IDS_SYNC_CONFIRM_PASSPHRASE_LABEL); | 176 AddString(dict, "confirmLabel", IDS_SYNC_CONFIRM_PASSPHRASE_LABEL); |
170 AddString(dict, "emptyErrorMessage", IDS_SYNC_EMPTY_PASSPHRASE_ERROR); | 177 AddString(dict, "emptyErrorMessage", IDS_SYNC_EMPTY_PASSPHRASE_ERROR); |
171 AddString(dict, "mismatchErrorMessage", IDS_SYNC_PASSPHRASE_MISMATCH_ERROR); | 178 AddString(dict, "mismatchErrorMessage", IDS_SYNC_PASSPHRASE_MISMATCH_ERROR); |
172 | 179 |
173 AddString(dict, "passphraseWarning", IDS_SYNC_PASSPHRASE_WARNING); | 180 AddString(dict, "passphraseWarning", IDS_SYNC_PASSPHRASE_WARNING); |
174 AddString(dict, "cleardata", IDS_SYNC_CLEAR_DATA_FOR_PASSPHRASE); | 181 AddString(dict, "cleardata", IDS_SYNC_CLEAR_DATA_FOR_PASSPHRASE); |
175 AddString(dict, "cleardatalink", IDS_SYNC_CLEAR_DATA_LINK); | 182 AddString(dict, "cleardatalink", IDS_SYNC_CLEAR_DATA_LINK); |
176 | 183 |
177 AddString(dict, "learnmore", IDS_LEARN_MORE); | 184 AddString(dict, "learnmore", IDS_LEARN_MORE); |
178 dict->SetString("encryptionhelpurl", | 185 dict->SetString("encryptionhelpurl", |
179 GetLocalizedUrl(kEncryptionHelpUrl)); | 186 GetLocalizedUrl(kEncryptionHelpUrl)); |
180 | 187 |
181 // Stuff for the footer. | 188 // Stuff for the footer. |
| 189 AddString(dict, "customizelinklabel", IDS_SYNC_CUSTOMIZE_LINK_LABEL); |
182 AddString(dict, "ok", IDS_OK); | 190 AddString(dict, "ok", IDS_OK); |
183 AddString(dict, "cancel", IDS_CANCEL); | 191 AddString(dict, "cancel", IDS_CANCEL); |
184 } else if (path_raw == kSyncPassphrasePath) { | 192 } else if (path_raw == kSyncPassphrasePath) { |
185 html_resource_id = IDR_SYNC_PASSPHRASE_HTML; | 193 html_resource_id = IDR_SYNC_PASSPHRASE_HTML; |
186 AddString(dict, "enterPassphraseTitle", IDS_SYNC_ENTER_PASSPHRASE_TITLE); | 194 AddString(dict, "enterPassphraseTitle", IDS_SYNC_ENTER_PASSPHRASE_TITLE); |
187 AddString(dict, "enterPassphraseBody", IDS_SYNC_ENTER_PASSPHRASE_BODY); | 195 AddString(dict, "enterPassphraseBody", IDS_SYNC_ENTER_PASSPHRASE_BODY); |
188 AddString(dict, "enterOtherPassphraseBody", | 196 AddString(dict, "enterOtherPassphraseBody", |
189 IDS_SYNC_ENTER_OTHER_PASSPHRASE_BODY); | 197 IDS_SYNC_ENTER_OTHER_PASSPHRASE_BODY); |
190 AddString(dict, "passphraseLabel", IDS_SYNC_PASSPHRASE_LABEL); | 198 AddString(dict, "passphraseLabel", IDS_SYNC_PASSPHRASE_LABEL); |
191 AddString(dict, "incorrectPassphrase", IDS_SYNC_INCORRECT_PASSPHRASE); | 199 AddString(dict, "incorrectPassphrase", IDS_SYNC_INCORRECT_PASSPHRASE); |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
339 result = GAIA_SUCCESS; | 347 result = GAIA_SUCCESS; |
340 } else if (start_state == ENTER_PASSPHRASE || | 348 } else if (start_state == ENTER_PASSPHRASE || |
341 start_state == CONFIGURE || | 349 start_state == CONFIGURE || |
342 start_state == PASSPHRASE_MIGRATION) { | 350 start_state == PASSPHRASE_MIGRATION) { |
343 result = DONE; | 351 result = DONE; |
344 } | 352 } |
345 DCHECK_NE(FATAL_ERROR, result) << | 353 DCHECK_NE(FATAL_ERROR, result) << |
346 "Invalid start state for discrete run: " << start_state; | 354 "Invalid start state for discrete run: " << start_state; |
347 return result; | 355 return result; |
348 } | 356 } |
OLD | NEW |