| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ | 6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <ostream> | 9 #include <ostream> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 void StartLso(); | 146 void StartLso(); |
| 147 | 147 |
| 148 // Called from Arc support platform app to set auth code and start arc. | 148 // Called from Arc support platform app to set auth code and start arc. |
| 149 void SetAuthCodeAndStartArc(const std::string& auth_code); | 149 void SetAuthCodeAndStartArc(const std::string& auth_code); |
| 150 | 150 |
| 151 // Called from Arc support platform app when user cancels signing. | 151 // Called from Arc support platform app when user cancels signing. |
| 152 void CancelAuthCode(); | 152 void CancelAuthCode(); |
| 153 | 153 |
| 154 bool IsArcManaged() const; | 154 bool IsArcManaged() const; |
| 155 bool IsArcEnabled() const; | 155 bool IsArcEnabled() const; |
| 156 |
| 157 // This requires Arc to be allowed (|IsAllowed|)for current profile. |
| 156 void EnableArc(); | 158 void EnableArc(); |
| 157 void DisableArc(); | 159 void DisableArc(); |
| 158 | 160 |
| 159 // syncable_prefs::PrefServiceSyncableObserver | 161 // syncable_prefs::PrefServiceSyncableObserver |
| 160 void OnIsSyncingChanged() override; | 162 void OnIsSyncingChanged() override; |
| 161 | 163 |
| 162 // syncable_prefs::SyncedPrefObserver | 164 // syncable_prefs::SyncedPrefObserver |
| 163 void OnSyncedPrefChanged(const std::string& path, bool from_sync) override; | 165 void OnSyncedPrefChanged(const std::string& path, bool from_sync) override; |
| 164 | 166 |
| 165 // ArcAuthContextDelegate: | 167 // ArcAuthContextDelegate: |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 219 base::WeakPtrFactory<ArcAuthService> weak_ptr_factory_; | 221 base::WeakPtrFactory<ArcAuthService> weak_ptr_factory_; |
| 220 | 222 |
| 221 DISALLOW_COPY_AND_ASSIGN(ArcAuthService); | 223 DISALLOW_COPY_AND_ASSIGN(ArcAuthService); |
| 222 }; | 224 }; |
| 223 | 225 |
| 224 std::ostream& operator<<(std::ostream& os, const ArcAuthService::State& state); | 226 std::ostream& operator<<(std::ostream& os, const ArcAuthService::State& state); |
| 225 | 227 |
| 226 } // namespace arc | 228 } // namespace arc |
| 227 | 229 |
| 228 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ | 230 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_AUTH_SERVICE_H_ |
| OLD | NEW |