| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ | 5 #ifndef CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ |
| 6 #define CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ | 6 #define CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 // tests. This prevents the token service from trying to look up system | 44 // tests. This prevents the token service from trying to look up system |
| 45 // accounts which requires special permission. | 45 // accounts which requires special permission. |
| 46 static void set_is_testing_profile() { is_testing_profile_ = true; } | 46 static void set_is_testing_profile() { is_testing_profile_ = true; } |
| 47 | 47 |
| 48 // OAuth2TokenServiceDelegate overrides: | 48 // OAuth2TokenServiceDelegate overrides: |
| 49 bool RefreshTokenIsAvailable(const std::string& account_id) const override; | 49 bool RefreshTokenIsAvailable(const std::string& account_id) const override; |
| 50 bool RefreshTokenHasError(const std::string& account_id) const override; | 50 bool RefreshTokenHasError(const std::string& account_id) const override; |
| 51 void UpdateAuthError(const std::string& account_id, | 51 void UpdateAuthError(const std::string& account_id, |
| 52 const GoogleServiceAuthError& error) override; | 52 const GoogleServiceAuthError& error) override; |
| 53 std::vector<std::string> GetAccounts() override; | 53 std::vector<std::string> GetAccounts() override; |
| 54 bool NeedsAccountIdNameMap() const override; |
| 54 | 55 |
| 55 // Lists account names at the OS level. | 56 // Lists account names at the OS level. |
| 56 std::vector<std::string> GetSystemAccountNames(); | 57 std::vector<std::string> GetSystemAccountNames(); |
| 57 | 58 |
| 58 void ValidateAccounts(JNIEnv* env, | 59 void ValidateAccounts(JNIEnv* env, |
| 59 jobject obj, | 60 jobject obj, |
| 60 jstring current_account, | 61 jstring current_account, |
| 61 jboolean force_notifications); | 62 jboolean force_notifications); |
| 62 | 63 |
| 63 // Takes a the signed in sync account as well as all the other | 64 // Takes a the signed in sync account as well as all the other |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 | 149 |
| 149 AccountTrackerService* account_tracker_service_; | 150 AccountTrackerService* account_tracker_service_; |
| 150 RefreshTokenLoadStatus fire_refresh_token_loaded_; | 151 RefreshTokenLoadStatus fire_refresh_token_loaded_; |
| 151 | 152 |
| 152 static bool is_testing_profile_; | 153 static bool is_testing_profile_; |
| 153 | 154 |
| 154 DISALLOW_COPY_AND_ASSIGN(OAuth2TokenServiceDelegateAndroid); | 155 DISALLOW_COPY_AND_ASSIGN(OAuth2TokenServiceDelegateAndroid); |
| 155 }; | 156 }; |
| 156 | 157 |
| 157 #endif // CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ | 158 #endif // CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_DELEGATE_ANDROID_H_ |
| OLD | NEW |