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

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc

Issue 878913003: Added flag gaia-endpoint for testing with different flows (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update after review Created 5 years, 10 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 unified diff | Download patch
OLDNEW
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 #include "chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.h" 5 #include "chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 } 215 }
216 216
217 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 217 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
218 218
219 const GURL gaia_url = 219 const GURL gaia_url =
220 command_line->HasSwitch(::switches::kGaiaUrl) 220 command_line->HasSwitch(::switches::kGaiaUrl)
221 ? GURL(command_line->GetSwitchValueASCII(::switches::kGaiaUrl)) 221 ? GURL(command_line->GetSwitchValueASCII(::switches::kGaiaUrl))
222 : GaiaUrls::GetInstance()->gaia_url(); 222 : GaiaUrls::GetInstance()->gaia_url();
223 params.SetString("gaiaUrl", gaia_url.spec()); 223 params.SetString("gaiaUrl", gaia_url.spec());
224 224
225 if (command_line->HasSwitch(switches::kGaiaEndpointChromeOS)) {
226 params.SetString("gaiaEndpoint", command_line->GetSwitchValueASCII(
227 switches::kGaiaEndpointChromeOS));
228 }
225 if (context.embedded_signin_enabled) { 229 if (context.embedded_signin_enabled) {
226 params.SetBoolean("useEmbedded", true); 230 params.SetBoolean("useEmbedded", true);
227 // We set 'constrained' here to switch troubleshooting page on embedded 231 // We set 'constrained' here to switch troubleshooting page on embedded
228 // signin to full tab. 232 // signin to full tab.
229 params.SetInteger("constrained", 1); 233 params.SetInteger("constrained", 1);
230 } 234 }
231 235
232 frame_state_ = FRAME_STATE_LOADING; 236 frame_state_ = FRAME_STATE_LOADING;
233 CallJS("loadAuthExtension", params); 237 CallJS("loadAuthExtension", params);
234 } 238 }
(...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after
751 755
752 SigninScreenHandlerDelegate* GaiaScreenHandler::Delegate() { 756 SigninScreenHandlerDelegate* GaiaScreenHandler::Delegate() {
753 DCHECK(signin_screen_handler_); 757 DCHECK(signin_screen_handler_);
754 return signin_screen_handler_->delegate_; 758 return signin_screen_handler_->delegate_;
755 } 759 }
756 760
757 void GaiaScreenHandler::SetSigninScreenHandler(SigninScreenHandler* handler) { 761 void GaiaScreenHandler::SetSigninScreenHandler(SigninScreenHandler* handler) {
758 signin_screen_handler_ = handler; 762 signin_screen_handler_ = handler;
759 } 763 }
760 } // namespace chromeos 764 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/resources/chromeos/login/screen_gaia_signin.js ('k') | chromeos/chromeos_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698