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 "chrome/browser/sync/profile_sync_service.h" | 5 #include "chrome/browser/sync/profile_sync_service.h" |
6 | 6 |
7 #include <cstddef> | 7 #include <cstddef> |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1690 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1701 sync_driver::user_selectable_type::PASSWORDS, | 1701 sync_driver::user_selectable_type::PASSWORDS, |
1702 sync_driver::user_selectable_type::AUTOFILL, | 1702 sync_driver::user_selectable_type::AUTOFILL, |
1703 sync_driver::user_selectable_type::THEMES, | 1703 sync_driver::user_selectable_type::THEMES, |
1704 sync_driver::user_selectable_type::TYPED_URLS, | 1704 sync_driver::user_selectable_type::TYPED_URLS, |
1705 sync_driver::user_selectable_type::EXTENSIONS, | 1705 sync_driver::user_selectable_type::EXTENSIONS, |
1706 sync_driver::user_selectable_type::APPS, | 1706 sync_driver::user_selectable_type::APPS, |
1707 sync_driver::user_selectable_type::WIFI_CREDENTIAL, | 1707 sync_driver::user_selectable_type::WIFI_CREDENTIAL, |
1708 sync_driver::user_selectable_type::PROXY_TABS, | 1708 sync_driver::user_selectable_type::PROXY_TABS, |
1709 }; | 1709 }; |
1710 | 1710 |
1711 static_assert(35 == syncer::MODEL_TYPE_COUNT, | 1711 static_assert(36 == syncer::MODEL_TYPE_COUNT, |
1712 "custom config histogram must be updated"); | 1712 "custom config histogram must be updated"); |
1713 | 1713 |
1714 if (!sync_everything) { | 1714 if (!sync_everything) { |
1715 const syncer::ModelTypeSet current_types = GetPreferredDataTypes(); | 1715 const syncer::ModelTypeSet current_types = GetPreferredDataTypes(); |
1716 | 1716 |
1717 syncer::ModelTypeSet type_set = syncer::UserSelectableTypes(); | 1717 syncer::ModelTypeSet type_set = syncer::UserSelectableTypes(); |
1718 syncer::ModelTypeSet::Iterator it = type_set.First(); | 1718 syncer::ModelTypeSet::Iterator it = type_set.First(); |
1719 | 1719 |
1720 DCHECK_EQ(arraysize(user_selectable_types), type_set.Size()); | 1720 DCHECK_EQ(arraysize(user_selectable_types), type_set.Size()); |
1721 | 1721 |
(...skipping 1026 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2748 } else { | 2748 } else { |
2749 UMA_HISTOGRAM_COUNTS("Sync.MemoryPressureWarningBeforeCleanShutdown", | 2749 UMA_HISTOGRAM_COUNTS("Sync.MemoryPressureWarningBeforeCleanShutdown", |
2750 warning_received); | 2750 warning_received); |
2751 } | 2751 } |
2752 } | 2752 } |
2753 sync_prefs_.SetMemoryPressureWarningCount(0); | 2753 sync_prefs_.SetMemoryPressureWarningCount(0); |
2754 // Will set to true during a clean shutdown, so crash or something else will | 2754 // Will set to true during a clean shutdown, so crash or something else will |
2755 // remain this as false. | 2755 // remain this as false. |
2756 sync_prefs_.SetCleanShutdown(false); | 2756 sync_prefs_.SetCleanShutdown(false); |
2757 } | 2757 } |
OLD | NEW |