| 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 #ifndef COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 5 #ifndef COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
| 6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 238 std::unique_ptr<syncer::SyncClient> sync_client; | 238 std::unique_ptr<syncer::SyncClient> sync_client; |
| 239 std::unique_ptr<SigninManagerWrapper> signin_wrapper; | 239 std::unique_ptr<SigninManagerWrapper> signin_wrapper; |
| 240 ProfileOAuth2TokenService* oauth2_token_service = nullptr; | 240 ProfileOAuth2TokenService* oauth2_token_service = nullptr; |
| 241 GaiaCookieManagerService* gaia_cookie_manager_service = nullptr; | 241 GaiaCookieManagerService* gaia_cookie_manager_service = nullptr; |
| 242 StartBehavior start_behavior = MANUAL_START; | 242 StartBehavior start_behavior = MANUAL_START; |
| 243 syncer::NetworkTimeUpdateCallback network_time_update_callback; | 243 syncer::NetworkTimeUpdateCallback network_time_update_callback; |
| 244 base::FilePath base_directory; | 244 base::FilePath base_directory; |
| 245 scoped_refptr<net::URLRequestContextGetter> url_request_context; | 245 scoped_refptr<net::URLRequestContextGetter> url_request_context; |
| 246 std::string debug_identifier; | 246 std::string debug_identifier; |
| 247 version_info::Channel channel = version_info::Channel::UNKNOWN; | 247 version_info::Channel channel = version_info::Channel::UNKNOWN; |
| 248 scoped_refptr<base::SingleThreadTaskRunner> db_thread; | |
| 249 scoped_refptr<base::SingleThreadTaskRunner> file_thread; | |
| 250 base::SequencedWorkerPool* blocking_pool = nullptr; | 248 base::SequencedWorkerPool* blocking_pool = nullptr; |
| 251 | 249 |
| 252 private: | 250 private: |
| 253 DISALLOW_COPY_AND_ASSIGN(InitParams); | 251 DISALLOW_COPY_AND_ASSIGN(InitParams); |
| 254 }; | 252 }; |
| 255 | 253 |
| 256 explicit ProfileSyncService(InitParams init_params); | 254 explicit ProfileSyncService(InitParams init_params); |
| 257 | 255 |
| 258 ~ProfileSyncService() override; | 256 ~ProfileSyncService() override; |
| 259 | 257 |
| (...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 819 // The request context in which sync should operate. | 817 // The request context in which sync should operate. |
| 820 scoped_refptr<net::URLRequestContextGetter> url_request_context_; | 818 scoped_refptr<net::URLRequestContextGetter> url_request_context_; |
| 821 | 819 |
| 822 // An identifier representing this instance for debugging purposes. | 820 // An identifier representing this instance for debugging purposes. |
| 823 std::string debug_identifier_; | 821 std::string debug_identifier_; |
| 824 | 822 |
| 825 // The product channel of the embedder. | 823 // The product channel of the embedder. |
| 826 version_info::Channel channel_; | 824 version_info::Channel channel_; |
| 827 | 825 |
| 828 // Threading context. | 826 // Threading context. |
| 829 scoped_refptr<base::SingleThreadTaskRunner> db_thread_; | |
| 830 scoped_refptr<base::SingleThreadTaskRunner> file_thread_; | |
| 831 base::SequencedWorkerPool* blocking_pool_; | 827 base::SequencedWorkerPool* blocking_pool_; |
| 832 | 828 |
| 833 // Indicates if this is the first time sync is being configured. This value | 829 // Indicates if this is the first time sync is being configured. This value |
| 834 // is equal to !IsFirstSetupComplete() at the time of OnBackendInitialized(). | 830 // is equal to !IsFirstSetupComplete() at the time of OnBackendInitialized(). |
| 835 bool is_first_time_sync_configure_; | 831 bool is_first_time_sync_configure_; |
| 836 | 832 |
| 837 // Number of UIs currently configuring the Sync service. When this number | 833 // Number of UIs currently configuring the Sync service. When this number |
| 838 // is decremented back to zero, Sync setup is marked no longer in progress. | 834 // is decremented back to zero, Sync setup is marked no longer in progress. |
| 839 int outstanding_setup_in_progress_handles_ = 0; | 835 int outstanding_setup_in_progress_handles_ = 0; |
| 840 | 836 |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1007 base::WeakPtrFactory<ProfileSyncService> weak_factory_; | 1003 base::WeakPtrFactory<ProfileSyncService> weak_factory_; |
| 1008 | 1004 |
| 1009 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); | 1005 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); |
| 1010 }; | 1006 }; |
| 1011 | 1007 |
| 1012 bool ShouldShowActionOnUI(const syncer::SyncProtocolError& error); | 1008 bool ShouldShowActionOnUI(const syncer::SyncProtocolError& error); |
| 1013 | 1009 |
| 1014 } // namespace browser_sync | 1010 } // namespace browser_sync |
| 1015 | 1011 |
| 1016 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 1012 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
| OLD | NEW |