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

Side by Side Diff: chrome/browser/sync/profile_sync_service.h

Issue 551843003: Persist Directory to disk when the app is backgrounded. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address nits. Created 6 years, 2 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
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 CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after
782 BrowsingDataRemover::Observer* observer); 782 BrowsingDataRemover::Observer* observer);
783 void SetClearingBrowseringDataForTesting(base::Callback< 783 void SetClearingBrowseringDataForTesting(base::Callback<
784 void(BrowsingDataRemover::Observer*, Profile*, base::Time, base::Time)> 784 void(BrowsingDataRemover::Observer*, Profile*, base::Time, base::Time)>
785 c); 785 c);
786 786
787 // Return the base URL of the Sync Server. 787 // Return the base URL of the Sync Server.
788 static GURL GetSyncServiceURL(const base::CommandLine& command_line); 788 static GURL GetSyncServiceURL(const base::CommandLine& command_line);
789 789
790 base::Time GetDeviceBackupTimeForTesting() const; 790 base::Time GetDeviceBackupTimeForTesting() const;
791 791
792 // This triggers a Directory::SaveChanges() call on the sync thread.
793 // It should be used to persist data to disk when the process might be
794 // killed in the near future.
795 void FlushDirectory() const;
796
792 protected: 797 protected:
793 // Helper to configure the priority data types. 798 // Helper to configure the priority data types.
794 void ConfigurePriorityDataTypes(); 799 void ConfigurePriorityDataTypes();
795 800
796 // Helper to install and configure a data type manager. 801 // Helper to install and configure a data type manager.
797 void ConfigureDataTypeManager(); 802 void ConfigureDataTypeManager();
798 803
799 // Shuts down the backend sync components. 804 // Shuts down the backend sync components.
800 // |reason| dictates if syncing is being disabled or not, and whether 805 // |reason| dictates if syncing is being disabled or not, and whether
801 // to claim ownership of sync thread from backend. 806 // to claim ownership of sync thread from backend.
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
1159 BrowsingDataRemover::Observer* browsing_data_remover_observer_; 1164 BrowsingDataRemover::Observer* browsing_data_remover_observer_;
1160 1165
1161 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); 1166 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService);
1162 }; 1167 };
1163 1168
1164 bool ShouldShowActionOnUI( 1169 bool ShouldShowActionOnUI(
1165 const syncer::SyncProtocolError& error); 1170 const syncer::SyncProtocolError& error);
1166 1171
1167 1172
1168 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 1173 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/sync_backend_host_mock.cc ('k') | chrome/browser/sync/profile_sync_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698