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

Side by Side Diff: chrome/browser/signin/chrome_signin_client.cc

Issue 872433006: Disconnect one click sign in code. The code itself will be removed in followup (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/chrome_signin_client.h" 5 #include "chrome/browser/signin/chrome_signin_client.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/guid.h" 8 #include "base/guid.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 cache.SetLocalAuthCredentialsOfProfileAtIndex(index, std::string()); 172 cache.SetLocalAuthCredentialsOfProfileAtIndex(index, std::string());
173 cache.SetUserNameOfProfileAtIndex(index, base::string16()); 173 cache.SetUserNameOfProfileAtIndex(index, base::string16());
174 cache.SetProfileSigninRequiredAtIndex(index, false); 174 cache.SetProfileSigninRequiredAtIndex(index, false);
175 } 175 }
176 176
177 net::URLRequestContextGetter* ChromeSigninClient::GetURLRequestContext() { 177 net::URLRequestContextGetter* ChromeSigninClient::GetURLRequestContext() {
178 return profile_->GetRequestContext(); 178 return profile_->GetRequestContext();
179 } 179 }
180 180
181 bool ChromeSigninClient::ShouldMergeSigninCredentialsIntoCookieJar() { 181 bool ChromeSigninClient::ShouldMergeSigninCredentialsIntoCookieJar() {
182 // If inline sign in is enabled, but account consistency is not, the user's 182 return !switches::IsEnableAccountConsistency();
183 // credentials should be merge into the cookie jar.
184 return !switches::IsEnableWebBasedSignin() &&
185 !switches::IsEnableAccountConsistency();
186 } 183 }
187 184
188 std::string ChromeSigninClient::GetProductVersion() { 185 std::string ChromeSigninClient::GetProductVersion() {
189 chrome::VersionInfo chrome_version; 186 chrome::VersionInfo chrome_version;
190 return chrome_version.CreateVersionString(); 187 return chrome_version.CreateVersionString();
191 } 188 }
192 189
193 bool ChromeSigninClient::IsFirstRun() const { 190 bool ChromeSigninClient::IsFirstRun() const {
194 #if defined(OS_ANDROID) 191 #if defined(OS_ANDROID)
195 return false; 192 return false;
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 256
260 ProfileInfoCache& cache = g_browser_process->profile_manager()-> 257 ProfileInfoCache& cache = g_browser_process->profile_manager()->
261 GetProfileInfoCache(); 258 GetProfileInfoCache();
262 size_t index = cache.GetIndexOfProfileWithPath(profile_->GetPath()); 259 size_t index = cache.GetIndexOfProfileWithPath(profile_->GetPath());
263 if (index == std::string::npos) 260 if (index == std::string::npos)
264 return; 261 return;
265 262
266 cache.SetProfileIsAuthErrorAtIndex(index, 263 cache.SetProfileIsAuthErrorAtIndex(index,
267 signin_error_controller_->HasError()); 264 signin_error_controller_->HasError());
268 } 265 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698