Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(467)

Side by Side Diff: components/sync_driver/sync_prefs.h

Issue 919383002: Remove some dead code about "acknowledged types" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « components/sync_driver/pref_names.cc ('k') | components/sync_driver/sync_prefs.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_ 5 #ifndef COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_
6 #define COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_ 6 #define COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 // Maps |data_type| to its corresponding preference name. 116 // Maps |data_type| to its corresponding preference name.
117 static const char* GetPrefNameForDataType(syncer::ModelType data_type); 117 static const char* GetPrefNameForDataType(syncer::ModelType data_type);
118 118
119 #if defined(OS_CHROMEOS) 119 #if defined(OS_CHROMEOS)
120 // Use this spare bootstrap token only when setting up sync for the first 120 // Use this spare bootstrap token only when setting up sync for the first
121 // time. 121 // time.
122 std::string GetSpareBootstrapToken() const; 122 std::string GetSpareBootstrapToken() const;
123 void SetSpareBootstrapToken(const std::string& token); 123 void SetSpareBootstrapToken(const std::string& token);
124 #endif 124 #endif
125 125
126 // Merges the given set of types with the set of acknowledged types.
127 void AcknowledgeSyncedTypes(syncer::ModelTypeSet types);
128
129 // Get/Set number of rollback attempts allowed. 126 // Get/Set number of rollback attempts allowed.
130 virtual int GetRemainingRollbackTries() const; 127 virtual int GetRemainingRollbackTries() const;
131 virtual void SetRemainingRollbackTries(int times); 128 virtual void SetRemainingRollbackTries(int times);
132 129
133 // Get/set/clear first sync time of current user. Used to roll back browsing 130 // Get/set/clear first sync time of current user. Used to roll back browsing
134 // data later when user signs out. 131 // data later when user signs out.
135 base::Time GetFirstSyncTime() const; 132 base::Time GetFirstSyncTime() const;
136 void SetFirstSyncTime(base::Time time); 133 void SetFirstSyncTime(base::Time time);
137 void ClearFirstSyncTime(); 134 void ClearFirstSyncTime();
138 135
139 // For testing. 136 // For testing.
140 137
141 void SetManagedForTest(bool is_managed); 138 void SetManagedForTest(bool is_managed);
142 syncer::ModelTypeSet GetAcknowledgeSyncedTypesForTest() const;
143 139
144 private: 140 private:
145 void RegisterPrefGroups(); 141 void RegisterPrefGroups();
146 142
147 static void RegisterDataTypePreferredPref( 143 static void RegisterDataTypePreferredPref(
148 user_prefs::PrefRegistrySyncable* prefs, 144 user_prefs::PrefRegistrySyncable* prefs,
149 syncer::ModelType type, 145 syncer::ModelType type,
150 bool is_preferred); 146 bool is_preferred);
151 bool GetDataTypePreferred(syncer::ModelType type) const; 147 bool GetDataTypePreferred(syncer::ModelType type) const;
152 void SetDataTypePreferred(syncer::ModelType type, bool is_preferred); 148 void SetDataTypePreferred(syncer::ModelType type, bool is_preferred);
(...skipping 23 matching lines...) Expand all
176 // etc. 172 // etc.
177 typedef std::map<syncer::ModelType, syncer::ModelTypeSet> PrefGroupsMap; 173 typedef std::map<syncer::ModelType, syncer::ModelTypeSet> PrefGroupsMap;
178 PrefGroupsMap pref_groups_; 174 PrefGroupsMap pref_groups_;
179 175
180 DISALLOW_COPY_AND_ASSIGN(SyncPrefs); 176 DISALLOW_COPY_AND_ASSIGN(SyncPrefs);
181 }; 177 };
182 178
183 } // namespace sync_driver 179 } // namespace sync_driver
184 180
185 #endif // COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_ 181 #endif // COMPONENTS_SYNC_DRIVER_SYNC_PREFS_H_
OLDNEW
« no previous file with comments | « components/sync_driver/pref_names.cc ('k') | components/sync_driver/sync_prefs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698