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

Side by Side Diff: chrome/browser/sync/glue/sync_backend_host.cc

Issue 10832286: sync: Introduce control data types (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unit tests Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #include "chrome/browser/sync/glue/sync_backend_host.h" 7 #include "chrome/browser/sync/glue/sync_backend_host.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <map> 10 #include <map>
(...skipping 1298 matching lines...) Expand 10 before | Expand all | Expand 10 after
1309 case NOT_INITIALIZED: 1309 case NOT_INITIALIZED:
1310 // This configuration should result in a download request if the nigori 1310 // This configuration should result in a download request if the nigori
1311 // type's initial_sync_ended bit is unset. If the download request 1311 // type's initial_sync_ended bit is unset. If the download request
1312 // contains progress markers, there is a risk that the server will try to 1312 // contains progress markers, there is a risk that the server will try to
1313 // trigger migration. That would be disastrous, so we must rely on the 1313 // trigger migration. That would be disastrous, so we must rely on the
1314 // sync manager to ensure that this type never has both progress markers 1314 // sync manager to ensure that this type never has both progress markers
1315 // and !initial_sync_ended. 1315 // and !initial_sync_ended.
1316 initialization_state_ = DOWNLOADING_NIGORI; 1316 initialization_state_ = DOWNLOADING_NIGORI;
1317 ConfigureDataTypes( 1317 ConfigureDataTypes(
1318 syncer::CONFIGURE_REASON_NEW_CLIENT, 1318 syncer::CONFIGURE_REASON_NEW_CLIENT,
1319 syncer::ModelTypeSet(syncer::NIGORI), 1319 syncer::ModelTypeSet(syncer::EarlyDownloadTypes()),
1320 syncer::ModelTypeSet(), 1320 syncer::ModelTypeSet(),
1321 // Calls back into this function. 1321 // Calls back into this function.
1322 base::Bind( 1322 base::Bind(
1323 &SyncBackendHost:: 1323 &SyncBackendHost::
1324 HandleNigoriConfigurationCompletedOnFrontendLoop, 1324 HandleNigoriConfigurationCompletedOnFrontendLoop,
1325 weak_ptr_factory_.GetWeakPtr(), js_backend), 1325 weak_ptr_factory_.GetWeakPtr(), js_backend),
1326 base::Bind(&SyncBackendHost::OnNigoriDownloadRetry, 1326 base::Bind(&SyncBackendHost::OnNigoriDownloadRetry,
1327 weak_ptr_factory_.GetWeakPtr())); 1327 weak_ptr_factory_.GetWeakPtr()));
1328 break; 1328 break;
1329 case DOWNLOADING_NIGORI: 1329 case DOWNLOADING_NIGORI:
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
1529 FROM_HERE, 1529 FROM_HERE,
1530 base::Bind(&SyncBackendHost::Core::DoRefreshNigori, 1530 base::Bind(&SyncBackendHost::Core::DoRefreshNigori,
1531 core_.get(), sync_thread_done_callback)); 1531 core_.get(), sync_thread_done_callback));
1532 } 1532 }
1533 1533
1534 #undef SDVLOG 1534 #undef SDVLOG
1535 1535
1536 #undef SLOG 1536 #undef SLOG
1537 1537
1538 } // namespace browser_sync 1538 } // namespace browser_sync
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698