Index: chrome/browser/search_engines/template_url_service.h |
diff --git a/chrome/browser/search_engines/template_url_service.h b/chrome/browser/search_engines/template_url_service.h |
index 87469c271688df6190838fbd74429ba0b47ae7e6..4c50bedcc4e578b473e697f90f555ad495dc518e 100644 |
--- a/chrome/browser/search_engines/template_url_service.h |
+++ b/chrome/browser/search_engines/template_url_service.h |
@@ -354,6 +354,8 @@ class TemplateURLService : public WebDataServiceConsumer, |
FindDuplicateOfSyncTemplateURL); |
FRIEND_TEST_ALL_PREFIXES(TemplateURLServiceSyncTest, |
MergeSyncAndLocalURLDuplicates); |
+ FRIEND_TEST_ALL_PREFIXES(TemplateURLServiceSyncTest, |
+ PreSyncDeletes); |
friend class TemplateURLServiceTestUtil; |
@@ -545,6 +547,9 @@ class TemplateURLService : public WebDataServiceConsumer, |
// where old entries were being pushed to Sync without a sync_guid. |
void PatchMissingSyncGUIDs(TemplateURLVector* template_urls); |
+ // Adds |guid| to |pre_sync_deletes_|. |
+ void AddPreSyncDeletedGUIDForTesting(const std::string& guid); |
+ |
content::NotificationRegistrar notification_registrar_; |
PrefChangeRegistrar pref_change_registrar_; |
@@ -628,6 +633,12 @@ class TemplateURLService : public WebDataServiceConsumer, |
// the Synced default when the default search provider becomes unmanaged. |
bool pending_synced_default_search_; |
+ // A set of sync GUIDs denoting TemplateURLs that have been removed from this |
+ // model or the underlying WebDataService prior to MergeDataAndStartSyncing. |
+ // This set is used to determine what entries from the server we want to |
+ // ignore locally and return a delete command for. |
+ std::set<std::string> pre_sync_deletes_; |
Peter Kasting
2012/05/15 21:28:10
Is there any way to keep this as a local that's pa
SteveT
2012/05/16 13:26:43
That's a bit difficult. The reason is because the
|
+ |
DISALLOW_COPY_AND_ASSIGN(TemplateURLService); |
}; |