| 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 "components/sync/driver/glue/sync_backend_host_impl.h" | 5 #include "components/sync/driver/glue/sync_backend_host_impl.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 789 void SyncBackendHostImpl::HandleDirectoryUpdateCountersUpdatedOnFrontendLoop( | 789 void SyncBackendHostImpl::HandleDirectoryUpdateCountersUpdatedOnFrontendLoop( |
| 790 syncer::ModelType type, | 790 syncer::ModelType type, |
| 791 const syncer::UpdateCounters& counters) { | 791 const syncer::UpdateCounters& counters) { |
| 792 if (!frontend_) | 792 if (!frontend_) |
| 793 return; | 793 return; |
| 794 frontend_->OnDirectoryTypeUpdateCounterUpdated(type, counters); | 794 frontend_->OnDirectoryTypeUpdateCounterUpdated(type, counters); |
| 795 } | 795 } |
| 796 | 796 |
| 797 void SyncBackendHostImpl::HandleDirectoryStatusCountersUpdatedOnFrontendLoop( | 797 void SyncBackendHostImpl::HandleDirectoryStatusCountersUpdatedOnFrontendLoop( |
| 798 syncer::ModelType type, | 798 syncer::ModelType type, |
| 799 const syncer::StatusCounters& counters) { | 799 std::unique_ptr<syncer::StatusCounters> counters) { |
| 800 if (!frontend_) | 800 if (!frontend_) |
| 801 return; | 801 return; |
| 802 frontend_->OnDirectoryTypeStatusCounterUpdated(type, counters); | 802 frontend_->OnDatatypeStatusCounterUpdated(type, std::move(counters)); |
| 803 } | 803 } |
| 804 | 804 |
| 805 void SyncBackendHostImpl::UpdateInvalidationVersions( | 805 void SyncBackendHostImpl::UpdateInvalidationVersions( |
| 806 const std::map<syncer::ModelType, int64_t>& invalidation_versions) { | 806 const std::map<syncer::ModelType, int64_t>& invalidation_versions) { |
| 807 sync_prefs_->UpdateInvalidationVersions(invalidation_versions); | 807 sync_prefs_->UpdateInvalidationVersions(invalidation_versions); |
| 808 } | 808 } |
| 809 | 809 |
| 810 base::MessageLoop* SyncBackendHostImpl::GetSyncLoopForTesting() { | 810 base::MessageLoop* SyncBackendHostImpl::GetSyncLoopForTesting() { |
| 811 return registrar_->sync_thread()->message_loop(); | 811 return registrar_->sync_thread()->message_loop(); |
| 812 } | 812 } |
| (...skipping 26 matching lines...) Expand all Loading... |
| 839 const syncer::SyncManager::ClearServerDataCallback& frontend_callback) { | 839 const syncer::SyncManager::ClearServerDataCallback& frontend_callback) { |
| 840 DCHECK(ui_thread_->BelongsToCurrentThread()); | 840 DCHECK(ui_thread_->BelongsToCurrentThread()); |
| 841 frontend_callback.Run(); | 841 frontend_callback.Run(); |
| 842 } | 842 } |
| 843 | 843 |
| 844 } // namespace browser_sync | 844 } // namespace browser_sync |
| 845 | 845 |
| 846 #undef SDVLOG | 846 #undef SDVLOG |
| 847 | 847 |
| 848 #undef SLOG | 848 #undef SLOG |
| OLD | NEW |