OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/glue/sync_backend_host_impl.h" | 5 #include "chrome/browser/sync/glue/sync_backend_host_impl.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "chrome/browser/chrome_notification_types.h" | 8 #include "chrome/browser/chrome_notification_types.h" |
9 #include "chrome/browser/invalidation/invalidation_service.h" | 9 #include "chrome/browser/invalidation/invalidation_service.h" |
10 #include "chrome/browser/invalidation/invalidation_service_factory.h" | 10 #include "chrome/browser/invalidation/invalidation_service_factory.h" |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 syncer::NetworkResources* network_resources) { | 84 syncer::NetworkResources* network_resources) { |
85 registrar_.reset(new browser_sync::SyncBackendRegistrar(name_, | 85 registrar_.reset(new browser_sync::SyncBackendRegistrar(name_, |
86 profile_, | 86 profile_, |
87 sync_thread.Pass())); | 87 sync_thread.Pass())); |
88 CHECK(registrar_->sync_thread()); | 88 CHECK(registrar_->sync_thread()); |
89 | 89 |
90 frontend_ = frontend; | 90 frontend_ = frontend; |
91 DCHECK(frontend); | 91 DCHECK(frontend); |
92 | 92 |
93 syncer::ModelSafeRoutingInfo routing_info; | 93 syncer::ModelSafeRoutingInfo routing_info; |
94 std::vector<syncer::ModelSafeWorker*> workers; | 94 std::vector<scoped_refptr<syncer::ModelSafeWorker> > workers; |
95 registrar_->GetModelSafeRoutingInfo(&routing_info); | 95 registrar_->GetModelSafeRoutingInfo(&routing_info); |
96 registrar_->GetWorkers(&workers); | 96 registrar_->GetWorkers(&workers); |
97 | 97 |
98 InternalComponentsFactory::Switches factory_switches = { | 98 InternalComponentsFactory::Switches factory_switches = { |
99 InternalComponentsFactory::ENCRYPTION_KEYSTORE, | 99 InternalComponentsFactory::ENCRYPTION_KEYSTORE, |
100 InternalComponentsFactory::BACKOFF_NORMAL | 100 InternalComponentsFactory::BACKOFF_NORMAL |
101 }; | 101 }; |
102 | 102 |
103 CommandLine* cl = CommandLine::ForCurrentProcess(); | 103 CommandLine* cl = CommandLine::ForCurrentProcess(); |
104 if (cl->HasSwitch(switches::kSyncShortInitialRetryOverride)) { | 104 if (cl->HasSwitch(switches::kSyncShortInitialRetryOverride)) { |
(...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
746 base::MessageLoop* SyncBackendHostImpl::GetSyncLoopForTesting() { | 746 base::MessageLoop* SyncBackendHostImpl::GetSyncLoopForTesting() { |
747 return registrar_->sync_thread()->message_loop(); | 747 return registrar_->sync_thread()->message_loop(); |
748 } | 748 } |
749 | 749 |
750 } // namespace browser_sync | 750 } // namespace browser_sync |
751 | 751 |
752 #undef SDVLOG | 752 #undef SDVLOG |
753 | 753 |
754 #undef SLOG | 754 #undef SLOG |
755 | 755 |
OLD | NEW |