Chromium Code Reviews| Index: chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc |
| diff --git a/chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc b/chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc |
| index 3c67a109027c7ab88fec7742b5a7b2036b29f94a..109de2209685ef97a4cce41138c55856db3afd51 100644 |
| --- a/chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc |
| +++ b/chrome/browser/ui/webui/chromeos/login/gaia_screen_handler.cc |
| @@ -41,6 +41,7 @@ |
| #include "google_apis/gaia/gaia_auth_util.h" |
| #include "google_apis/gaia/gaia_switches.h" |
| #include "google_apis/gaia/gaia_urls.h" |
| +#include "grit/browser_resources.h" |
| #include "ui/base/ime/chromeos/input_method_manager.h" |
| #include "ui/base/l10n/l10n_util.h" |
| @@ -55,9 +56,9 @@ const char kAuthIframeParentName[] = "signin-frame"; |
| const char kAuthIframeParentOrigin[] = |
| "chrome-extension://mfffpogegjflfpflabcdkioaeobkgjik/"; |
| -// TODO(rsorokin): Get rid of this url before the beta release. Issue tracking |
| +// TODO(rsorokin): Get rid of this before the beta release. Issue tracking |
| // that http://crbug/462204. |
| -const char kStagingGaiaUrl[] = "https://accounts.sandbox.google.com/"; |
| +const char kGaiaSandboxUrlSwitch[] = "gaia-sandbox-url"; |
|
Dmitry Polukhin
2015/03/13 11:56:20
We agreed to use accounts.sandbox.google.com tempo
Dmitry Polukhin
2015/03/17 17:51:43
As discussed it is not a problem. We will switch t
|
| // TODO(rsorokin): Move this to the proper file. |
| const char kMinuteMaidPath[] = "ChromeOsEmbeddedSetup"; |
| @@ -248,12 +249,16 @@ void GaiaScreenHandler::LoadGaia(const GaiaContext& context) { |
| } |
| if (!command_line->HasSwitch(::switches::kGaiaUrl) && |
| + command_line->HasSwitch(kGaiaSandboxUrlSwitch) && |
| StartupUtils::IsWebviewSigninEnabled()) { |
| // We can't use switch --gaia-url in this case cause we need get |
| // auth_code from staging gaia and make all the other auths against prod |
| // gaia so user could use all the google services. |
| + // Default to production Gaia for MM unless --gaia-url or --gaia-sandbox-url |
| + // is specified. |
| // TODO(dpolukhin): crbug.com/462204 |
| - const GURL gaia_url = GURL(kStagingGaiaUrl); |
| + const GURL gaia_url = |
| + GURL(command_line->GetSwitchValueASCII(kGaiaSandboxUrlSwitch)); |
| params.SetString("gaiaUrl", gaia_url.spec()); |
| } else { |
| const GURL gaia_url = |
| @@ -362,6 +367,9 @@ void GaiaScreenHandler::DeclareLocalizedValues( |
| void GaiaScreenHandler::GetAdditionalParameters(base::DictionaryValue* dict) { |
| dict->SetBoolean("isWebviewSignin", StartupUtils::IsWebviewSigninEnabled()); |
| + dict->SetString( |
| + "samlInjectedJS", |
| + l10n_util::GetStringUTF8(IDR_GAIA_AUTH_WEBVIEW_SAML_INJECTED_JS)); |
| } |
| void GaiaScreenHandler::Initialize() { |