| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ui/webui/sync_setup_handler.h" | 5 #include "chrome/browser/ui/webui/sync_setup_handler.h" |
| 6 | 6 |
| 7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/bind_helpers.h" | 9 #include "base/bind_helpers.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 | 70 |
| 71 SyncConfigInfo::~SyncConfigInfo() {} | 71 SyncConfigInfo::~SyncConfigInfo() {} |
| 72 | 72 |
| 73 const char* kDataTypeNames[] = { | 73 const char* kDataTypeNames[] = { |
| 74 "apps", | 74 "apps", |
| 75 "autofill", | 75 "autofill", |
| 76 "bookmarks", | 76 "bookmarks", |
| 77 "extensions", | 77 "extensions", |
| 78 "passwords", | 78 "passwords", |
| 79 "preferences", | 79 "preferences", |
| 80 "sessions", | 80 "tabs", |
| 81 "themes", | 81 "themes", |
| 82 "typedUrls" | 82 "typedUrls" |
| 83 }; | 83 }; |
| 84 | 84 |
| 85 const syncer::ModelType kDataTypes[] = { | 85 const syncer::ModelType kDataTypes[] = { |
| 86 syncer::APPS, | 86 syncer::APPS, |
| 87 syncer::AUTOFILL, | 87 syncer::AUTOFILL, |
| 88 syncer::BOOKMARKS, | 88 syncer::BOOKMARKS, |
| 89 syncer::EXTENSIONS, | 89 syncer::EXTENSIONS, |
| 90 syncer::PASSWORDS, | 90 syncer::PASSWORDS, |
| 91 syncer::PREFERENCES, | 91 syncer::PREFERENCES, |
| 92 syncer::SESSIONS, | 92 syncer::TABS, |
| 93 syncer::THEMES, | 93 syncer::THEMES, |
| 94 syncer::TYPED_URLS | 94 syncer::TYPED_URLS |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 static const size_t kNumDataTypes = arraysize(kDataTypes); | 97 static const size_t kNumDataTypes = arraysize(kDataTypes); |
| 98 COMPILE_ASSERT(arraysize(kDataTypeNames) == arraysize(kDataTypes), | 98 COMPILE_ASSERT(arraysize(kDataTypeNames) == arraysize(kDataTypes), |
| 99 kDataTypes_does_not_match_kDataTypeNames); | 99 kDataTypes_does_not_match_kDataTypeNames); |
| 100 | 100 |
| 101 static const char kDefaultSigninDomain[] = "gmail.com"; | 101 static const char kDefaultSigninDomain[] = "gmail.com"; |
| 102 | 102 |
| (...skipping 1154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1257 if (i != current_profile_index && AreUserNamesEqual( | 1257 if (i != current_profile_index && AreUserNamesEqual( |
| 1258 cache.GetUserNameOfProfileAtIndex(i), username_utf16)) { | 1258 cache.GetUserNameOfProfileAtIndex(i), username_utf16)) { |
| 1259 *error_message = l10n_util::GetStringUTF16( | 1259 *error_message = l10n_util::GetStringUTF16( |
| 1260 IDS_SYNC_USER_NAME_IN_USE_ERROR); | 1260 IDS_SYNC_USER_NAME_IN_USE_ERROR); |
| 1261 return false; | 1261 return false; |
| 1262 } | 1262 } |
| 1263 } | 1263 } |
| 1264 | 1264 |
| 1265 return true; | 1265 return true; |
| 1266 } | 1266 } |
| OLD | NEW |