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 #include "chrome/browser/signin/signin_tracker.h" | 5 #include "chrome/browser/signin/signin_tracker.h" |
6 | 6 |
| 7 #include "chrome/browser/chrome_notification_types.h" |
7 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
8 #include "chrome/browser/signin/signin_manager.h" | 9 #include "chrome/browser/signin/signin_manager.h" |
9 #include "chrome/browser/signin/signin_manager_factory.h" | 10 #include "chrome/browser/signin/signin_manager_factory.h" |
10 #include "chrome/browser/signin/token_service.h" | 11 #include "chrome/browser/signin/token_service.h" |
11 #include "chrome/browser/signin/token_service_factory.h" | 12 #include "chrome/browser/signin/token_service_factory.h" |
12 #include "chrome/common/chrome_notification_types.h" | |
13 #include "content/public/browser/notification_details.h" | 13 #include "content/public/browser/notification_details.h" |
14 #include "content/public/browser/notification_source.h" | 14 #include "content/public/browser/notification_source.h" |
15 #include "google_apis/gaia/gaia_constants.h" | 15 #include "google_apis/gaia/gaia_constants.h" |
16 | 16 |
17 static const char* kSignedInServices[] = { | 17 static const char* kSignedInServices[] = { |
18 GaiaConstants::kSyncService, | 18 GaiaConstants::kSyncService, |
19 GaiaConstants::kGaiaOAuth2LoginRefreshToken | 19 GaiaConstants::kGaiaOAuth2LoginRefreshToken |
20 }; | 20 }; |
21 static const int kNumSignedInServices = | 21 static const int kNumSignedInServices = |
22 arraysize(kSignedInServices); | 22 arraysize(kSignedInServices); |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
145 } | 145 } |
146 | 146 |
147 // If we haven't loaded all our service tokens yet, just exit (we'll be called | 147 // If we haven't loaded all our service tokens yet, just exit (we'll be called |
148 // again when another token is loaded, or will transition to SigninFailed if | 148 // again when another token is loaded, or will transition to SigninFailed if |
149 // the loading fails). | 149 // the loading fails). |
150 if (!AreServiceTokensLoaded(profile)) | 150 if (!AreServiceTokensLoaded(profile)) |
151 return SERVICES_INITIALIZING; | 151 return SERVICES_INITIALIZING; |
152 | 152 |
153 return SIGNIN_COMPLETE; | 153 return SIGNIN_COMPLETE; |
154 } | 154 } |
OLD | NEW |