OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/data_type_manager_impl.h" | 5 #include "components/sync/driver/data_type_manager_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <functional> | 8 #include <functional> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/bind_helpers.h" | 11 #include "base/bind_helpers.h" |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/logging.h" | 13 #include "base/logging.h" |
14 #include "base/metrics/histogram_macros.h" | 14 #include "base/metrics/histogram_macros.h" |
15 #include "base/profiler/scoped_tracker.h" | 15 #include "base/profiler/scoped_tracker.h" |
16 #include "base/strings/stringprintf.h" | 16 #include "base/strings/stringprintf.h" |
17 #include "base/threading/thread_task_runner_handle.h" | 17 #include "base/threading/thread_task_runner_handle.h" |
18 #include "base/trace_event/trace_event.h" | 18 #include "base/trace_event/trace_event.h" |
19 #include "components/sync/core/data_type_debug_info_listener.h" | |
20 #include "components/sync/driver/data_type_encryption_handler.h" | 19 #include "components/sync/driver/data_type_encryption_handler.h" |
21 #include "components/sync/driver/data_type_manager_observer.h" | 20 #include "components/sync/driver/data_type_manager_observer.h" |
22 #include "components/sync/driver/data_type_status_table.h" | 21 #include "components/sync/driver/data_type_status_table.h" |
| 22 #include "components/sync/engine/data_type_debug_info_listener.h" |
23 | 23 |
24 namespace syncer { | 24 namespace syncer { |
25 | 25 |
26 namespace { | 26 namespace { |
27 | 27 |
28 DataTypeStatusTable::TypeErrorMap GenerateCryptoErrorsForTypes( | 28 DataTypeStatusTable::TypeErrorMap GenerateCryptoErrorsForTypes( |
29 ModelTypeSet encrypted_types) { | 29 ModelTypeSet encrypted_types) { |
30 DataTypeStatusTable::TypeErrorMap crypto_errors; | 30 DataTypeStatusTable::TypeErrorMap crypto_errors; |
31 for (ModelTypeSet::Iterator iter = encrypted_types.First(); iter.Good(); | 31 for (ModelTypeSet::Iterator iter = encrypted_types.First(); iter.Good(); |
32 iter.Inc()) { | 32 iter.Inc()) { |
(...skipping 642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
675 DCHECK(!last_restart_time_.is_null()); | 675 DCHECK(!last_restart_time_.is_null()); |
676 configure_time_delta_ += (base::Time::Now() - last_restart_time_); | 676 configure_time_delta_ += (base::Time::Now() - last_restart_time_); |
677 } | 677 } |
678 | 678 |
679 ModelTypeSet DataTypeManagerImpl::GetEnabledTypes() const { | 679 ModelTypeSet DataTypeManagerImpl::GetEnabledTypes() const { |
680 return Difference(last_requested_types_, | 680 return Difference(last_requested_types_, |
681 data_type_status_table_.GetFailedTypes()); | 681 data_type_status_table_.GetFailedTypes()); |
682 } | 682 } |
683 | 683 |
684 } // namespace syncer | 684 } // namespace syncer |
OLD | NEW |