OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <list> | 9 #include <list> |
10 #include <string> | 10 #include <string> |
(...skipping 23 matching lines...) Expand all Loading... |
34 #include "chrome/common/net/gaia/google_service_auth_error.h" | 34 #include "chrome/common/net/gaia/google_service_auth_error.h" |
35 #include "content/public/browser/notification_observer.h" | 35 #include "content/public/browser/notification_observer.h" |
36 #include "content/public/browser/notification_registrar.h" | 36 #include "content/public/browser/notification_registrar.h" |
37 #include "content/public/browser/notification_types.h" | 37 #include "content/public/browser/notification_types.h" |
38 #include "googleurl/src/gurl.h" | 38 #include "googleurl/src/gurl.h" |
39 | 39 |
40 class Profile; | 40 class Profile; |
41 class ProfileSyncFactory; | 41 class ProfileSyncFactory; |
42 class SigninManager; | 42 class SigninManager; |
43 class SyncGlobalError; | 43 class SyncGlobalError; |
44 struct ChromeCookieDetails; | |
45 | 44 |
46 namespace browser_sync { | 45 namespace browser_sync { |
47 class BackendMigrator; | 46 class BackendMigrator; |
48 class ChangeProcessor; | 47 class ChangeProcessor; |
49 class DataTypeManager; | 48 class DataTypeManager; |
50 class JsController; | 49 class JsController; |
51 class SessionModelAssociator; | 50 class SessionModelAssociator; |
52 namespace sessions { struct SyncSessionSnapshot; } | 51 namespace sessions { struct SyncSessionSnapshot; } |
53 } | 52 } |
54 | 53 |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 // in some intermediate state. Those finer-grained intermediate states | 99 // in some intermediate state. Those finer-grained intermediate states |
101 // are differentiated by the DataTypeController state. | 100 // are differentiated by the DataTypeController state. |
102 // | 101 // |
103 class ProfileSyncService : public browser_sync::SyncFrontend, | 102 class ProfileSyncService : public browser_sync::SyncFrontend, |
104 public browser_sync::SyncPrefObserver, | 103 public browser_sync::SyncPrefObserver, |
105 public browser_sync::UnrecoverableErrorHandler, | 104 public browser_sync::UnrecoverableErrorHandler, |
106 public content::NotificationObserver, | 105 public content::NotificationObserver, |
107 // TODO(lipalani): crbug.com/100829. Instead of | 106 // TODO(lipalani): crbug.com/100829. Instead of |
108 // doing this vend weak pointers from a factory. | 107 // doing this vend weak pointers from a factory. |
109 public base::SupportsWeakPtr<ProfileSyncService> { | 108 public base::SupportsWeakPtr<ProfileSyncService> { |
110 | |
111 public: | 109 public: |
112 typedef ProfileSyncServiceObserver Observer; | 110 typedef ProfileSyncServiceObserver Observer; |
113 typedef browser_sync::SyncBackendHost::Status Status; | 111 typedef browser_sync::SyncBackendHost::Status Status; |
114 | 112 |
115 enum SyncEventCodes { | 113 enum SyncEventCodes { |
116 MIN_SYNC_EVENT_CODE = 0, | 114 MIN_SYNC_EVENT_CODE = 0, |
117 | 115 |
118 // Events starting the sync service. | 116 // Events starting the sync service. |
119 START_FROM_NTP = 1, // Sync was started from the ad in NTP | 117 START_FROM_NTP = 1, // Sync was started from the ad in NTP |
120 START_FROM_WRENCH = 2, // Sync was started from the Wrench menu. | 118 START_FROM_WRENCH = 2, // Sync was started from the Wrench menu. |
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
715 FailedDatatypesHandler failed_datatypes_handler_; | 713 FailedDatatypesHandler failed_datatypes_handler_; |
716 | 714 |
717 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); | 715 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); |
718 }; | 716 }; |
719 | 717 |
720 bool ShouldShowActionOnUI( | 718 bool ShouldShowActionOnUI( |
721 const browser_sync::SyncProtocolError& error); | 719 const browser_sync::SyncProtocolError& error); |
722 | 720 |
723 | 721 |
724 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 722 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
OLD | NEW |