Chromium Code Reviews| 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 "components/browser_sync/browser/profile_sync_service.h" | 5 #include "components/browser_sync/browser/profile_sync_service.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <cstddef> | 8 #include <cstddef> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 292 switches::kSyncEnableUSSDeviceInfo)) { | 292 switches::kSyncEnableUSSDeviceInfo)) { |
| 293 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner( | 293 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner( |
| 294 blocking_pool_->GetSequencedTaskRunnerWithShutdownBehavior( | 294 blocking_pool_->GetSequencedTaskRunnerWithShutdownBehavior( |
| 295 blocking_pool_->GetSequenceToken(), | 295 blocking_pool_->GetSequenceToken(), |
| 296 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN)); | 296 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN)); |
| 297 // TODO(skym): Stop creating leveldb files when signed out. | 297 // TODO(skym): Stop creating leveldb files when signed out. |
| 298 // TODO(skym): Verify using AsUTF8Unsafe is okay here. Should work as long | 298 // TODO(skym): Verify using AsUTF8Unsafe is okay here. Should work as long |
| 299 // as the Local State file is guaranteed to be UTF-8. | 299 // as the Local State file is guaranteed to be UTF-8. |
| 300 device_info_service_.reset(new DeviceInfoService( | 300 device_info_service_.reset(new DeviceInfoService( |
| 301 local_device_.get(), | 301 local_device_.get(), |
| 302 base::Bind(&ModelTypeStore::CreateStore, | 302 base::Bind(&ModelTypeStore::CreateStore, syncer::DEVICE_INFO, |
|
pavely
2016/06/08 01:18:07
Optional comment: If PSS performed conversion from
| |
| 303 directory_path_.Append(base::FilePath(kLevelDBFolderName)) | 303 directory_path_.Append(base::FilePath(kLevelDBFolderName)) |
| 304 .AsUTF8Unsafe(), | 304 .AsUTF8Unsafe(), |
| 305 blocking_task_runner), | 305 blocking_task_runner), |
| 306 base::Bind(&SharedModelTypeProcessor::CreateAsChangeProcessor))); | 306 base::Bind(&SharedModelTypeProcessor::CreateAsChangeProcessor))); |
| 307 } else { | 307 } else { |
| 308 device_info_sync_service_.reset( | 308 device_info_sync_service_.reset( |
| 309 new DeviceInfoSyncService(local_device_.get())); | 309 new DeviceInfoSyncService(local_device_.get())); |
| 310 } | 310 } |
| 311 | 311 |
| 312 sync_driver::SyncApiComponentFactory::RegisterDataTypesMethod | 312 sync_driver::SyncApiComponentFactory::RegisterDataTypesMethod |
| (...skipping 2221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2534 } | 2534 } |
| 2535 | 2535 |
| 2536 std::string ProfileSyncService::unrecoverable_error_message() const { | 2536 std::string ProfileSyncService::unrecoverable_error_message() const { |
| 2537 return unrecoverable_error_message_; | 2537 return unrecoverable_error_message_; |
| 2538 } | 2538 } |
| 2539 | 2539 |
| 2540 tracked_objects::Location ProfileSyncService::unrecoverable_error_location() | 2540 tracked_objects::Location ProfileSyncService::unrecoverable_error_location() |
| 2541 const { | 2541 const { |
| 2542 return unrecoverable_error_location_; | 2542 return unrecoverable_error_location_; |
| 2543 } | 2543 } |
| OLD | NEW |