Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2557)

Unified Diff: chrome/browser/policy/browser_policy_connector.cc

Issue 7562008: Add new version of enrollment screen supporting OAuth. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase, fix nit. Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/policy/browser_policy_connector.h ('k') | chrome/browser/resources/chromeos/login/oobe.css » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/policy/browser_policy_connector.cc
diff --git a/chrome/browser/policy/browser_policy_connector.cc b/chrome/browser/policy/browser_policy_connector.cc
index 05eb972eb729927e307bf5c4961f360d7c542366..922a2ca73d3cfa78151c7d1883f0aeecc4b17fa7 100644
--- a/chrome/browser/policy/browser_policy_connector.cc
+++ b/chrome/browser/policy/browser_policy_connector.cc
@@ -100,11 +100,21 @@ ConfigurationPolicyProvider*
void BrowserPolicyConnector::SetDeviceCredentials(
const std::string& owner_email,
- const std::string& gaia_token) {
+ const std::string& token,
+ TokenType token_type) {
#if defined(OS_CHROMEOS)
if (device_data_store_.get()) {
device_data_store_->set_user_name(owner_email);
- device_data_store_->SetGaiaToken(gaia_token);
+ switch (token_type) {
+ case TOKEN_TYPE_OAUTH:
+ device_data_store_->SetOAuthToken(token);
+ break;
+ case TOKEN_TYPE_GAIA:
+ device_data_store_->SetGaiaToken(token);
+ break;
+ default:
+ NOTREACHED() << "Invalid token type " << token_type;
+ }
}
#endif
}
« no previous file with comments | « chrome/browser/policy/browser_policy_connector.h ('k') | chrome/browser/resources/chromeos/login/oobe.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698